3v4l.org

run code in 300+ PHP versions simultaneously
<?php $currmonth = date('m', strtotime('-1 month')); echo $currmonth;

preferences:
38.46 ms | 402 KiB | 5 Q