Operators In Java

Dear Students, aaj ke is Lecture main hum Operators in java ke bare main. Yani ke operators kya hote hai operators in java ka use kya hota hai. Or sath me he operators kitne types ke hote hai. Operators se related ye sare topic ham operators in java ke lecture me cover karege.

Lectures Covering Topics

  • Introduction To Operators In Java
  • What Is Operators In Java In Hindi
  • Types Of Operators In Java In Hindi
  • Priority Of Operators In Java In Hindi

Introduction To Operators In Java

To student jab hum kisi variable main koi value store karte hai. To hum us value ke sath kuch operations bhi performs kar sakte hai. Jaise ki do numeric value ko aapas me addition, multiplication, divination karana.

Ya fir words ki value ko count, frequency, matching, coordination aadi karana. Ye sab kaam kisi na kisi operators ke help se he ho sakta hai. Theek isi tarah aap different type ki value ke saath alag alag operation perform kar sakte hai.

Kisi bhi variable ke sath koi bhi operation perform karne ke liye hame different operators ka use karna padta hai. To chaliye padte hai operator in java ke bare main.

What Is Operators In Java In Hindi

Jaisa ki mene aapko bataya ki operators ka use hum variables par operation perform karne ke liye karte hai. Sabhi data types par different types ke operation kiye jate hai. jaise ki multiply, addition, coordination etc.

Isi karan hum operators bhi different types ke use karte hai.Kisi bhi operation main jo bhi variable use kiye jate hai. Wo operand kahlate hai. Operators eak operand ke saath hi apply kiya jata hai.

Operator Binary or Unary two types ke hote hai. Binary operator 2 operands par apply kiye jate hai. Or unary operator sirf ek operand par apply kiya jata hai. Ab neeche likhe 1 line ke code se samjhte hai operators or operand kya hote hai.

Int X, Y, Z;

Z=X+Y;

Upar likhe code me x or y variable hai jo ki + operator ke sath use kiye gaye hai. Ye dono variable operand or + operator kahalate hai.

Types Of Operators In Java In Hindi

To student ab hum padege ki java me kitne types ke operators hote hai. Java me kai types ke operators hai joki neeche likhe hue hai.

  • Unary Operators
  • Arithmetic Operators
  • Relational Operators
  • Shift (Bitwise) Operators
  • Logical Operators
  • Ternary (Conditional) Operators
  • Assignment Operators

Types Of Operators In Java

Unary Operators in java

Unary operator ka use karne ke liye hame sirf eak operand ki jaroorat hoti hai. Is operator ka use hum various operations ke liye karte hai.

  • Value ko Increment/ Decrement karne ke liye
  • Kisi Boolean value ko change karne ke liye
  • Kisi expression ke unsuccessful karne ke liye

Unary Operators Example

Arithmetic Operators In Java

Arithmetic operators ka use hum mathematical operations ko perform karne ke liye karte hai. Ye five types ke hote hai addition, multiplication, subtraction, division, modules.

Arithmetic Operators Example

Shift (Bitwise) Operators In Java

Bitwise operators ka use bit by bit operations perform karne ke liye kiya jata hai. Ye operators variables ke value ko bit me convert karke un par operation perform karte hai.

Shift operators value ko bit bise manipulation karne main use kiya jata hai. Java main three types ke shift operators hote hai.

  • Left shift
  • Right shift
  • Right shift with zero fill >>> (or) unsigned right shift

Left Shift Operators Example

Right Shift Operators Example

Relational Operators In Java

Relational operators ka use 2 variables ke beech relation pata lagane ke liye kiya jata hai. Mostly inka use if statement main kiya jata hai. In operators ki helps aapko 2 variables ke beech relation pata chalta hai.

Jiase ki kya dono variable barabar hai ya fir eak choata ya bada hai. ye operators six types ke hote hai.

  • Equal to (==)
  • Not equal to (! =)
  • Greater than (>)
  • Less than (<)
  • Greater than equal to (>=)
  • Less than equal to(<=)

Relational Operators Example

Logical Operators In Java

Logical operators ka use hum Boolean values par operations perform karne ke liye karte hai. ye operators 3 tarah ke hote hai AND(&&), OR(||), NOT(!). Is tarah ke operations me dono variable ki value True ya False hoti hai.

Logical Operators Example

Ternary (Conditional) Operators In Java

Conditional operators ka use eak liner replacement ke roop me kiya jata hai. Yah operators 3 operand ko use karta hai. If-then-else statement ke sath use kiya jata hai. Ternary operators ko conditional operators bhi kha jata hai.

Conditional (Ternary) Operators Example

Assignment Operators in Java

Assignment operators ek most common operators hai. Is operators ka use value ko assing karne ke liye kiya jata hai. Kuch important assignment operators ke bare main neeche likha hua hai.

  • Simple assignment (=)
  • Plus assignment (+=)
  • Minus assignment (-=)
  • Multiply assignment ( * =)
  • Divide assignment (/=)

Assignment Operators Example

Priority Of Operators In Java In Hindi

Types Operators Category Priority
Unary postfix expr++ expr-
prefix ++expr –expr +expr -expr ~ !
Arithmetic multiplicative byte * / %
additive +-
Shift Shift << >> >>>
Relational comparison < > <= >= instanceof
equality == !=
Bitwise bitwise AND &
bitwise exclusive OR ^
bitwise inclusive OR |
Logical logical AND &&
logical OR ||
Ternary ternary ? :
Assignment assignment = += -= *= /= %= &= ^= |= <<= >>= >>>=

Related Lecture

Dear Students, main aasha karta hun ki aapko operators in java Ka Lecture padh kar samjh me aa gaya hoga ki java main operators kya hai hote hai. Yadi aapako (operators in java) ke Lecture se related koi bhi problem hai to aap hume comment karke puch skte hai.

Share This Post On

About Author

Thakur Aman Singh

Hey, I am Aman Singh Tomar from Taj City Agra. Through This Blog I want to share my Knowledge with all of you. Read More >>

Leave a Reply

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