aspose file tools*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Keyword vs Reserved Word! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Keyword vs Reserved Word!" Watch "Keyword vs Reserved Word!" New topic
Author

Keyword vs Reserved Word!

Kasi lingam
Greenhorn

Joined: Apr 01, 2003
Posts: 8
Hi all,
I am having little bit confusion regarding keywords and reserved words.
If suppose i m getting question like this, what will you choose in SCJP1.4 exam.
Which are the Java Keywords?
1)null
2)const
3)instanceof
4)goto
5)false
I have chosen 2,3,4 as keywords.But const,goto are reserved words.So the answer will be 3 only or all the three.?
And what is the difference between keywords and reserved words.?
Kindly someone explain me clearly..

Regards,
Kasi
Karthik Veeramani
Ranch Hand

Joined: Dec 22, 2002
Posts: 132
i guess const and goto can be chosen as keywords, bcoz thats the way i saw some books doing (when a question like this is given)... reserved words are those which are not supposed to be used by programmers as variable names etc. they are reserved by java, though not used.
About null, false and true, Sun classifies them as manifest constants and not keywords... to the extent ive seen in books, they are not listed under keywords category at all. So i guess it'll be safe to leave them out and choose the rest of the options... Moreover, the exam objectives clearly state that there wont be questions that deal with these differences (between manifest constants and keywords).
[ April 07, 2003: Message edited by: Karthik Veeramani ]

Thanks<br />Karthik<br />SCJP 1.4, CCNA.<br /> <br />"Success is relative. More the success, more the relatives."
Kasi lingam
Greenhorn

Joined: Apr 01, 2003
Posts: 8
Thanks Karthik.
So we can choose reserved words under keywords category right?
It means all reserved words are coming under keyword category.right?(in exam point of view i m asking)
Karthik Veeramani
Ranch Hand

Joined: Dec 22, 2002
Posts: 132
Thats how Ive seen in books And im going to write my exam in a couple of days, and thats wat im going to do
Kasi lingam
Greenhorn

Joined: Apr 01, 2003
Posts: 8
ok well said.
Best of luck for your exam.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Keyword vs Reserved Word!
 
Similar Threads
Keyword Again
java reserved words again....
Question on goto and const
confusion with the question
Is "goto" a Java keyword?