File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes A query on keywords Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "A query on keywords" Watch "A query on keywords" New topic
Author

A query on keywords

Rubayat Islam
Greenhorn

Joined: Feb 11, 2007
Posts: 6
The words
  • true
  • false
  • null
  • are not enlisted in the complete list of keywords of the K&B book, page 6. It should mean that i can use these as identifiers in my code. But complier detects error if i do so. Why aren't these words enlisted in the list then?


    Silence is the true Friend that never betrays...
    Sunil Vasudevan
    Ranch Hand

    Joined: Mar 05, 2007
    Posts: 107
    Null, false and true are not listed in reserved keywords cause they are actually literals. Hence cannot be used as an identifier.

    And FYI, literals are constant value (String or number) used in Java programs.

    A link to a good read is provided below:
    http://java.sun.com/docs/books/tutorial/java/nutsandbolts/datatypes.html


    Sunil.V<br />SCJP2, SCWCD1.4, SCBCD1.3
     
    I agree. Here's the link: http://aspose.com/file-tools
     
    subject: A query on keywords