3v4l.org

run code in 300+ PHP versions simultaneously
<?php print_r(get_thirty_days((new \DateTime())->getTimestamp())); function get_thirty_days(int $start_date_ts, int $days = null) { $days = $days ?? 30; $dates = []; while ($days--) { $dates[] = date('Y-m-d', $start_date_ts + ($days * (60 * 60 * 24))); } return $dates; }
Output for git.master, git.master_jit, rfc.property-hooks
Array ( [0] => 2018-01-30 [1] => 2018-01-29 [2] => 2018-01-28 [3] => 2018-01-27 [4] => 2018-01-26 [5] => 2018-01-25 [6] => 2018-01-24 [7] => 2018-01-23 [8] => 2018-01-22 [9] => 2018-01-21 [10] => 2018-01-20 [11] => 2018-01-19 [12] => 2018-01-18 [13] => 2018-01-17 [14] => 2018-01-16 [15] => 2018-01-15 [16] => 2018-01-14 [17] => 2018-01-13 [18] => 2018-01-12 [19] => 2018-01-11 [20] => 2018-01-10 [21] => 2018-01-09 [22] => 2018-01-08 [23] => 2018-01-07 [24] => 2018-01-06 [25] => 2018-01-05 [26] => 2018-01-04 [27] => 2018-01-03 [28] => 2018-01-02 [29] => 2018-01-01 )

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:
133.09 ms | 407 KiB | 5 Q