Arithmetic Operators in Java
• + : Addition
• - : Subtraction
• * : Multiplication
• / : Division
• % : Modulus
• ++ : Increment
• -- : Decrement
Relational Operators in Java
• == : Equal to
• != : Not equal to
• > : Greater than
• < : Less than
• >= : Greater than or equal to
• <= : Less than or equal to
Variables and Data Types in Java
• int : Integer
• float : Floating point number
• double : Floating point number
• char : Character
, • boolean : True or false
Boolean Expressions and Logic Operations in Java
• && : Logical AND
• || : Logical OR
• ! : Logical NOT
Decision-making with if, else statements in Java
• if : Used for true condition
• else : Used for false condition
• else if : Used for multiple conditions
Variables and Data Types in Java
In Java, there are different data types available which can be categorized into:
1. Primitive data types
• Numeric types: int , float , double , long , short , byte
• Character type: char
• Boolean type: boolean
2. Non-primitive data types or Reference data types
• Classes
• Interfaces
• Arrays
Variables
Variables are used to store data. A variable must be declared before it can be used.
Declaring a variable includes specifying its type and name.
• + : Addition
• - : Subtraction
• * : Multiplication
• / : Division
• % : Modulus
• ++ : Increment
• -- : Decrement
Relational Operators in Java
• == : Equal to
• != : Not equal to
• > : Greater than
• < : Less than
• >= : Greater than or equal to
• <= : Less than or equal to
Variables and Data Types in Java
• int : Integer
• float : Floating point number
• double : Floating point number
• char : Character
, • boolean : True or false
Boolean Expressions and Logic Operations in Java
• && : Logical AND
• || : Logical OR
• ! : Logical NOT
Decision-making with if, else statements in Java
• if : Used for true condition
• else : Used for false condition
• else if : Used for multiple conditions
Variables and Data Types in Java
In Java, there are different data types available which can be categorized into:
1. Primitive data types
• Numeric types: int , float , double , long , short , byte
• Character type: char
• Boolean type: boolean
2. Non-primitive data types or Reference data types
• Classes
• Interfaces
• Arrays
Variables
Variables are used to store data. A variable must be declared before it can be used.
Declaring a variable includes specifying its type and name.