Token and their types available in Java.

Q2. What is meant by token? Name the tokens available in Java.

Ans. Individual words and punctuation marks are called tokens. Every unit that makes a sentence in Java is a token.

The smallest individual unit in a program is known as a Token.

Java has the following types of tokens:

  1. Keywords
  2. Identifiers
  3. Literals
  4. Punctuators
  5. Operators

Leave a Reply

Your email address will not be published. Required fields are marked *

77 Views
%d bloggers like this: