3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php printf("%u\n",0xffffffffffffffff ); // 0 printf("%d\n",0xffffffffffffffff ); // 0 printf("%f\n", hexdec("0xffffffffffffffff")); printf("%f\n",pow(2,62)-1); // max integer that can be stored as floating pt value (2 ** 53) -1: var_dump( 0x001fffffffffffff ); // float 9.007199254741E+15 var_dump( (int) 0x001fffffffffffff); // int -1
Output for 5.2.1 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
0 0 18446744073709551616.000000 4611686018427387904.000000 int(9007199254740991) int(9007199254740991)
Output for 4.3.0 - 5.0.1, 5.0.3 - 5.0.5, 5.1.1 - 5.2.0
0 0 18446744073709552000.000000 4611686018427388000.000000 int(9007199254740991) int(9007199254740991)
Output for 5.1.0
Fatal error: fatal flex scanner internal error--end of buffer missed in /in/FIMNF on line 9
Process exited with code 255.
Output for 5.0.2
4294967295 9223372036854775807 18446744073709552000.000000 4611686018427388000.000000 int(9007199254740991) int(9007199254740991)