3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $n = 10; $a = new SplFixedArray($n); for($i = 0; $i < $n; $i++) $a[$i] = range(1,RAND(10,100)); print count($a[$i-1]); print count($a);
Output for 5.3.10, 5.3.20, 5.4.21, 5.4.43, 7.1.0
3310
Output for 5.4.20, 7.0.14
6810
Output for 5.6.17, 7.0.6
4310
Output for 7.0.5
7110
Output for 7.0.4
8110
Output for 5.3.23, 5.4.9, 5.4.27, 5.6.28, 7.0.3
4510
Output for 5.5.25, 5.5.31, 7.0.2
9410
Output for 5.4.22, 5.4.25, 5.4.38, 7.0.1
3110
Output for 5.4.24, 5.4.36, 7.0.0
8810
Output for 5.5.32, 5.6.21
10010
Output for 5.6.20
4210
Output for 5.6.19
7710
Output for 5.3.15, 5.6.8, 5.6.18
4810
Output for 5.4.8, 5.4.28, 5.6.16
1210
Output for 5.3.13, 5.6.15
3710
Output for 5.3.27, 5.6.14
2910
Output for 5.5.33, 5.6.13
1810
Output for 5.6.12
9810
Output for 5.6.11
4110
Output for 5.3.25, 5.6.10
5610
Output for 5.4.14, 5.4.23, 5.6.9
3210
Output for 5.5.35
4010
Output for 5.5.34
4710
Output for 5.4.30, 5.5.30
6510
Output for 5.5.29
5410
Output for 5.4.5, 5.5.28
6610
Output for 5.5.27
5510
Output for 5.5.26
3010
Output for 5.5.24
3810
Output for 5.3.14, 5.4.45
6310
Output for 5.4.6, 5.4.44
3610
Output for 5.3.6, 5.4.42
2810
Output for 5.3.0, 5.4.41
4910
Output for 5.4.40
1110
Output for 5.4.2, 5.4.11, 5.4.35, 5.4.39
6710
Output for 5.3.1, 5.4.37
7810
Output for 5.4.31, 5.4.34
9010
Output for 5.4.1, 5.4.32
7010
Output for 5.4.29
8310
Output for 5.4.7, 5.4.26
6110
Output for 5.4.19
2110
Output for 5.3.2, 5.4.18
8210
Output for 5.3.11, 5.4.17
9310
Output for 5.4.16
6910
Output for 5.4.15
7910
Output for 5.3.12, 5.3.22, 5.4.13
1710
Output for 5.3.4, 5.3.21, 5.4.12
7610
Output for 5.4.0, 5.4.10
5010
Output for 5.3.16, 5.4.4
8610
Output for 5.4.3
8410
Output for 5.3.19, 5.3.29
6410
Output for 5.3.28
2410
Output for 5.3.26
1610
Output for 5.3.9, 5.3.24
1010
Output for 5.3.18
5210
Output for 5.3.3, 5.3.17
2710
Output for 5.3.8
9510
Output for 5.3.7
2510
Output for 5.3.5
9210
Output for 5.0.0 - 5.2.17
Fatal error: Class 'SplFixedArray' not found in /in/P7KOe on line 3
Process exited with code 255.
Output for 4.3.2 - 4.4.9
Fatal error: Cannot instantiate non-existent class: splfixedarray in /in/P7KOe on line 3
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Cannot instantiate non-existent class: splfixedarray in /in/P7KOe on line 3