3v4l.org

run code in 300+ PHP versions simultaneously
<?php $txt=" gopu.phaneendra"; echo"hellp"; function add() { $x=20; $y=15; $z=$x+$y; echo $z; $Z++; } function sub() { $x=20; $y=14; $z=$x-$y; echo $z; $z--; } function mul() { $x=20; $y=15; $z=20*15; echo $z; } function mod() { $x=10; $y=20; $z=$x%y; echo $x; Echo $y; echo $z; } function div() { $x=20; $y=2; $z=$x/$y; echo $z; } add(); add(); sub(); sub(); mul(); mod(); div();
Output for 8.0.0 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.6
hellp35 Warning: Undefined variable $Z in /in/fSm8l on line 10 35 Warning: Undefined variable $Z in /in/fSm8l on line 10 66300 Fatal error: Uncaught Error: Undefined constant "y" in /in/fSm8l:31 Stack trace: #0 /in/fSm8l(48): mod() #1 {main} thrown in /in/fSm8l on line 31
Process exited with code 255.
Output for 7.2.0 - 7.2.33, 7.3.0 - 7.3.31, 7.4.0 - 7.4.33
hellp35 Notice: Undefined variable: Z in /in/fSm8l on line 10 35 Notice: Undefined variable: Z in /in/fSm8l on line 10 66300 Warning: Use of undefined constant y - assumed 'y' (this will throw an Error in a future version of PHP) in /in/fSm8l on line 31 Warning: A non-numeric value encountered in /in/fSm8l on line 31 Fatal error: Uncaught DivisionByZeroError: Modulo by zero in /in/fSm8l:31 Stack trace: #0 /in/fSm8l(48): mod() #1 {main} thrown in /in/fSm8l on line 31
Process exited with code 255.
Output for 7.3.32 - 7.3.33
hellp353566300 Warning: Use of undefined constant y - assumed 'y' (this will throw an Error in a future version of PHP) in /in/fSm8l on line 31 Warning: A non-numeric value encountered in /in/fSm8l on line 31 Fatal error: Uncaught DivisionByZeroError: Modulo by zero in /in/fSm8l:31 Stack trace: #0 /in/fSm8l(48): mod() #1 {main} thrown in /in/fSm8l on line 31
Process exited with code 255.
Output for 7.1.0 - 7.1.25
hellp35 Notice: Undefined variable: Z in /in/fSm8l on line 10 35 Notice: Undefined variable: Z in /in/fSm8l on line 10 66300 Notice: Use of undefined constant y - assumed 'y' in /in/fSm8l on line 31 Warning: A non-numeric value encountered in /in/fSm8l on line 31 Fatal error: Uncaught DivisionByZeroError: Modulo by zero in /in/fSm8l:31 Stack trace: #0 /in/fSm8l(48): mod() #1 {main} thrown in /in/fSm8l on line 31
Process exited with code 255.
Output for 7.0.0 - 7.0.20
hellp35 Notice: Undefined variable: Z in /in/fSm8l on line 10 35 Notice: Undefined variable: Z in /in/fSm8l on line 10 66300 Notice: Use of undefined constant y - assumed 'y' in /in/fSm8l on line 31 Fatal error: Uncaught DivisionByZeroError: Modulo by zero in /in/fSm8l:31 Stack trace: #0 /in/fSm8l(48): mod() #1 {main} thrown in /in/fSm8l on line 31
Process exited with code 255.
Output for 5.2.0 - 5.2.17, 5.3.0 - 5.3.29, 5.4.0 - 5.4.45, 5.5.24 - 5.5.35, 5.6.7 - 5.6.28
hellp35 Notice: Undefined variable: Z in /in/fSm8l on line 10 35 Notice: Undefined variable: Z in /in/fSm8l on line 10 66300 Notice: Use of undefined constant y - assumed 'y' in /in/fSm8l on line 31 Warning: Division by zero in /in/fSm8l on line 31 102010
Output for 5.0.4 - 5.0.5, 5.1.0 - 5.1.6
hellp35 Notice: Undefined variable: Z in /in/fSm8l on line 10 35 Notice: Undefined variable: Z in /in/fSm8l on line 10 66300 Notice: Use of undefined constant y - assumed 'y' in /in/fSm8l on line 31 102010
Output for 4.3.0 - 4.3.11, 4.4.0 - 4.4.4, 5.0.0 - 5.0.3
hellp35 Notice: Undefined variable: Z in /in/fSm8l on line 10 35 Notice: Undefined variable: Z in /in/fSm8l on line 10 66300 Notice: Use of undefined constant y - assumed 'y' in /in/fSm8l on line 31 102010
Output for 4.4.5 - 4.4.9
hellp35 Notice: Undefined variable: Z in /in/fSm8l on line 10 35 Notice: Undefined variable: Z in /in/fSm8l on line 10 66300 Notice: Use of undefined constant y - assumed 'y' in /in/fSm8l on line 31 Warning: Division by zero in /in/fSm8l on line 31 102010

preferences:
254.88 ms | 402 KiB | 328 Q