0
Is this name- a-variable-name for a variable wrong?.and if it is wrong then what's the reason.
Plz reply
7 Réponses
+ 2
No, you can't as hyphen or dash is treated as subtract operator by the compiler...
+ 15
Devang Soni variable name is not consist any hypen or special characters other than underscore that's why thr name you made for variable is wrong please read this naming convention.
https://www.sololearn.com/learn/CPlusPlus/1624/?ref=app
+ 1
What do you mean? Please clarify your doubt.
0
I mean that if we want to name a variable then is this name wrong?- ' a-variable-name
0
Yes , it's wrong
Use _ Except -