Difference between revisions of "Misc"
From Suhrid.net Wiki
Jump to navigationJump to searchLine 7: | Line 7: | ||
* Must start with letter, currency char, underscore but CANNOT start with a digit ! | * Must start with letter, currency char, underscore but CANNOT start with a digit ! | ||
* Java identifiers are case-sensitive. | * Java identifiers are case-sensitive. | ||
+ | |||
+ | Illegal identifiers: | ||
+ | * int 23age; | ||
+ | * String em@iladd; | ||
+ | * List all-accounts; | ||
+ | |||
+ | These are legal!: | ||
+ | * int __; | ||
+ | * String $; |
Revision as of 04:06, 20 June 2011
This covers Objective 1.3
Legal Identifiers
- Can be composed of characters, numbers, currency-symbols and connecting chars such as underscore.
- Definition of characters are interpreted according to the charset.
- NO special chars such as #, :, ;, @, -, etc...
- Must start with letter, currency char, underscore but CANNOT start with a digit !
- Java identifiers are case-sensitive.
Illegal identifiers:
- int 23age;
- String em@iladd;
- List all-accounts;
These are legal!:
- int __;
- String $;