3v4l.org

run code in 300+ PHP versions simultaneously
<?php foreach(range(0, 7) as $no) { $date1 = new DateTime('2014-01-01'); $date2 = new DateTime("today +{$no} week"); printf("Woche %d: %d\n", $no, $date1->diff($date2)->days / 7 % 3+1); }
Output for git.master, git.master_jit, rfc.property-hooks
Deprecated: Implicit conversion from float 46.285714285714285 to int loses precision in /in/dLC9E on line 6 Woche 0: 2 Deprecated: Implicit conversion from float 47.285714285714285 to int loses precision in /in/dLC9E on line 6 Woche 1: 3 Deprecated: Implicit conversion from float 48.285714285714285 to int loses precision in /in/dLC9E on line 6 Woche 2: 1 Deprecated: Implicit conversion from float 49.285714285714285 to int loses precision in /in/dLC9E on line 6 Woche 3: 2 Deprecated: Implicit conversion from float 50.285714285714285 to int loses precision in /in/dLC9E on line 6 Woche 4: 3 Deprecated: Implicit conversion from float 51.285714285714285 to int loses precision in /in/dLC9E on line 6 Woche 5: 1 Deprecated: Implicit conversion from float 52.285714285714285 to int loses precision in /in/dLC9E on line 6 Woche 6: 2 Deprecated: Implicit conversion from float 53.285714285714285 to int loses precision in /in/dLC9E on line 6 Woche 7: 3

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
33.38 ms | 403 KiB | 8 Q