+ 4

Could You tell me please, why the result of the code below is not 5 but 6?

https://code.sololearn.com/wABSm7kc2qUj/?ref=app

20th Aug 2019, 9:30 AM
Egor Tonchev(EGO)
Egor Tonchev(EGO) - avatar
3 Antworten
+ 2
If there was a global $b statement above the return statement the output would be 5.
20th Aug 2019, 9:43 AM
Sonic
Sonic - avatar
+ 2
Thank You both
22nd Aug 2019, 7:13 PM
Egor Tonchev(EGO)
Egor Tonchev(EGO) - avatar