3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $date_period = new DatePeriod(new DateTime(), new DateInterval("P1W"), (new DateTime())->add(new DateInterval("P1Y"))); foreach ($date_period as $date) { echo $date->format('l') . '\n'; }
based on MDmPV
Output for 5.4.0 - 5.4.32, 5.5.29, 5.6.11, 5.6.14, 5.6.17, 5.6.20, 5.6.28, 7.0.0, 7.0.5, 7.0.14 - 7.1.0
Saturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\nSaturday\n
Output for 5.5.26, 5.5.33, 5.6.12, 5.6.15, 5.6.18, 7.0.2, 7.0.6
Tuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\nTuesday\n
Output for 5.5.25, 5.5.32, 7.0.4
Thursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\nThursday\n
Output for 5.4.34 - 5.4.38, 5.5.27, 5.5.30, 5.6.8, 5.6.13, hhvm-3.12.0, 7.0.3
Friday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\nFriday\n
Output for 5.4.42, 5.5.28, 5.6.9, hhvm-3.10.0, 7.0.1
Wednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\nWednesday\n
Output for 5.4.39 - 5.4.41, 5.4.43 - 5.5.24, 5.6.10, 5.6.19, 5.6.21
Monday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\nMonday\n
Output for 5.5.31, 5.5.34 - 5.5.35, 5.6.16
Sunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\nSunday\n
Output for 4.4.2 - 4.4.9, 5.1.0 - 5.3.29
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /in/5tGUV on line 2
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1, 5.0.0 - 5.0.5
Parse error: parse error, unexpected T_OBJECT_OPERATOR in /in/5tGUV on line 2
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error in /in/5tGUV on line 2
Process exited with code 255.