my dog learned polymorphism*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes \u0063 is a indetifier Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "\u0063 is a indetifier " Watch "\u0063 is a indetifier " New topic
Author

\u0063 is a indetifier

Mihai Radulescu
Ranch Hand

Joined: Sep 18, 2003
Posts: 916

I just found this in "Test cafe "v.3.00
char \u0063='\u0063' -is ok .
I try it but javac says:"...[10:1] not a statement".
Who is right


SCJP, SCJD, SCWCD, OCPJBCD
Lakshmi Saradha
Ranch Hand

Joined: Oct 21, 2003
Posts: 170
Hi,
I am using the jdk1.4 compiler. This piece of code did not give any complilation error? What is the version of the compiler you are using?


Thanks,<br />Lakshmi.
dennis zined
Ranch Hand

Joined: Mar 07, 2003
Posts: 330
\u0063 is not an identifier. It is the unicode representation of the c character.
Compile the ff. code:

Decompiling it shows the ff. revised code:

[ November 27, 2003: Message edited by: dennis zined ]

SCJP 1.4<br />SCWCD 1.4
Marlene Miller
Ranch Hand

Joined: Mar 05, 2003
Posts: 1391
char \u0063='\u0063' -is ok .
Hi RihaiM, the semicolon ; is missing. Could that be the reason for your compiler error?
char \u0063='\u0063';
----
Is \u0063 a Unicode representation of the character c or is \u0063 a Java language representation of a Unicode character?
dennis zined
Ranch Hand

Joined: Mar 07, 2003
Posts: 330
Hi meticulous Marlene. Good point....it is a Java language representation of a Unicode character.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: \u0063 is a indetifier