Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

want to know

 
Ravinder Partap
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to ask Is int e# illegal identifier name ? Why.
 
marc weber
Sheriff
Posts: 11343
Java Mac Safari
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to JavaRanch!

Have you tried this? Did it work?

See JLS - 3.8 Identifiers.
 
Amit Bhat
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Rules for Legal Identifiers

Definition: Letter = (A-Z, a-z or '$' or '_' )
Definition: Digit = ( 0 -9 )


An Identifier:
Must begin with a letter, '$', or "_".
After the first char, any char that is a letter (including '$' or '_') or digit may be used.
Cannot be a reserved word (aka keyword).
No spaces are allowed in the identifier.
Cannot have a Java operator symbol (because not a letter or digit).
No limit to the number of letters & digits (0 - 9).
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic