Quote:
Originally Posted by GrimR
Yeah that's for a single line statement only, a lot of languages do that.
A multi line statement is usually stricter with requirement for parenthesis.
The compiler might be allowing it, but I would be concerned as to whether it really works as intended lol.
pawn Код:
if(c > 1 && c <= 1 + len) { licenseplate[c] = numberstr[c - 2]; } else switch(c) { case 0, 1: licenseplate[c] = random('Z' - 'A') + 'A'; default: licenseplate[c] = random('9' - '0') + '0'; }
Your if has only one line statement but has parenthesis, your else has a switch and 2 statements but no parenthesis..... It could be valid but it looks like a bad habit to get into.
I'll take a look.
|
Alright, I'll do it that way from now on, thanks.
Now please lets go back to my matter.