3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php namespace WebSharks\Challenge; $a = ['patdumona', 'kristinedp', 'raamdes', 'renzmp', 'reedysete']; print_r(str_replace(strlen($a[$i]),strlen($a-4),$a,$i));
based on jp6dM
Output for 7.0.0 - 7.2.0
Notice: Undefined variable: i in /in/qc3fK on line 4 Notice: Undefined index: in /in/qc3fK on line 4 Fatal error: Uncaught Error: Unsupported operand types in /in/qc3fK:4 Stack trace: #0 {main} thrown in /in/qc3fK on line 4
Process exited with code 255.
Output for 5.4.11 - 5.6.21
Notice: Undefined variable: i in /in/qc3fK on line 4 Notice: Undefined index: in /in/qc3fK on line 4 Fatal error: Unsupported operand types in /in/qc3fK on line 4
Process exited with code 255.
Output for 5.3.21 - 5.3.29
Parse error: syntax error, unexpected '[' in /in/qc3fK on line 3
Process exited with code 255.