I am writing this code in php
$a = 1 + 2 + 3 − 4 + 5;
echo $a;
getting error
Parse error: syntax error, unexpected '−' (T_STRING) in E:\xampp\htdocs\practice\test\index.php on line 2
what's the problem what's the right code
Remove the operators and type them in again yourself. Looks like you copied them from somewhere and its not the correct operators php is expecting.
Eg. - and − are not the same thing.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With