3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array(); $arr[] = 'or'; echo $arr[0]; $arr[] = 'aviv'; echo $arr[0]; unset($arr[]); $arr = array(); $arr[] = 'not or'; echo $arr[0];
Output for 5.4.1 - 5.4.45, 5.5.24 - 5.5.29, 5.6.8 - 5.6.13
Fatal error: Cannot use [] for unsetting in /in/MmQQi on line 8
Process exited with code 255.

preferences:
185.6 ms | 1395 KiB | 63 Q