FAQ

Java

JSP

Servlet


Advertisement



Are true, false, and null Java keywords?

The true, false, and null are not Java keywords, but they are reserved words. Remember that all keywords are reserved words, but not vice versa. Java keywords and reserved words can not be used as identifiers such as variable, class, or method names.

Java Language Specification has differentiated between the two to specify that reserved literals represents a value for a primitive,object or null type. On the other hand, you cannot assign keywords as values to primitives,objects or null type.


Printer-friendly version Printer-friendly version | Send this 
article to a friend Mail this to a friend

Previous Next vertical dots separating previous/next from contents/index/pdf Contents

  |   |