ankitweblogic logo
W e b t u t o r i a l s

Define Java

C vs C++ vs Java

Java Virtual Machine

Set Java Path

Java Tokens

Reserved Keywords

Identifiers

Literals

Operators

Operator Precedence

Escape Sequences

Java Literals

In Java, Literals are a sequence of characters (digits, letters and other characters) that represent constant values to be stored in variables. Java language specifies 5 major types of literals. They are:
Integer literals
Floating_point literals
Character literals
String literals
Boolean literals