SlideShare a Scribd company logo
Operators in C
Assignment Operators
Assignment Operators
An assignment operator is used for assigning a value to a variable.
Consider A=15
Operator Description Example
= Simple assignment operator. Assigns values from right
side operands to left side operand
C = A will assign the value of A
to C i.e., C is 15
+= Add AND assignment operator. It adds the right
operand to the left operand and assign the result to the
left operand.
C += A is equivalent to C= C + A
i.e., now C will be 15+15=30.
-= Subtract AND assignment operator. It subtracts the
right operand from the left operand and assigns the
result to the left operand.
C -= A is equivalent to C = C – A
i.e., now C will be 30-15= 15.
*= Multiply AND assignment operator. It multiplies the
right operand with the left operand and assigns the
result to the left operand.
C *= A is equivalent to C = C *
A i.e., now value of C will be
15*15= 225.
Operator Description Example
/= Divide AND assignment operator. It divides
the left operand with the right operand and
assigns the result to the left operand.
C /= A is equivalent to C = C / A
i.e., value of C will be 225/15=15
%= Modulus AND assignment operator. It takes
modulus using two operands and assigns the
result to the left operand.
C %= A is equivalent to C = C % A
i.e., value of C will be 15%5=0
<<= Left shift AND assignment operator. A <<= 2 is same as A = A << 2
i.e., value of A will be 15<<2=60
>>= Right shift AND assignment operator. A >>= 2 is same as A = A >> 2
i.e., value of A will be 60>>2=15
&= Bitwise AND assignment operator. A &= 2 is same as A= A & 2 i.e., value of A
will be 15&=2 is 2
^= Bitwise exclusive OR and assignment
operator.
A ^= 2 is same as A = A ^ 2 value of A will
be 15^=2 is 0
|= Bitwise inclusive OR and assignment operator. A |= 2 is same as A = A | 2 value of A will be
15|=2 is 2
Continue…
Assignment operators
THANK YOU
Ad

More Related Content

What's hot (20)

The Importance of English Communication in Education
The Importance of English Communication in EducationThe Importance of English Communication in Education
The Importance of English Communication in Education
Intelligence Vidyarthi
 
Green Theorem
Green TheoremGreen Theorem
Green Theorem
Sarwan Ursani
 
Introduction to c++
Introduction to c++Introduction to c++
Introduction to c++
somu rajesh
 
Cauchy Eular Differential Equation
Cauchy Eular Differential EquationCauchy Eular Differential Equation
Cauchy Eular Differential Equation
FahadAhmed116
 
Differential calculus
Differential calculus  Differential calculus
Differential calculus
Santhanam Krishnan
 
Laws of boolean algebra
Laws of boolean algebraLaws of boolean algebra
Laws of boolean algebra
ArunaDevi63
 
Integral calculus
Integral calculusIntegral calculus
Integral calculus
Farzad Javidanrad
 
MATLAB Programming
MATLAB Programming MATLAB Programming
MATLAB Programming
محمدعبد الحى
 
Toc 1 | gate | Theory of computation
Toc 1 | gate | Theory of computationToc 1 | gate | Theory of computation
Toc 1 | gate | Theory of computation
narayan dudhe
 
Fourier series
Fourier seriesFourier series
Fourier series
Naveen Sihag
 
LinearAlgebra.ppt
LinearAlgebra.pptLinearAlgebra.ppt
LinearAlgebra.ppt
vijaykumar838577
 
Lab manual of C++
Lab manual of C++Lab manual of C++
Lab manual of C++
thesaqib
 
Quantum mechanics for Engineering Students
Quantum mechanics for Engineering StudentsQuantum mechanics for Engineering Students
Quantum mechanics for Engineering Students
Praveen Vaidya
 
5. lec5 curl of a vector
5. lec5 curl of a vector5. lec5 curl of a vector
5. lec5 curl of a vector
shabdrang
 
08 decrease and conquer spring 15
08 decrease and conquer spring 1508 decrease and conquer spring 15
08 decrease and conquer spring 15
Hira Gul
 
The vector or cross product
The vector or cross productThe vector or cross product
The vector or cross product
Sabir Ahmed
 
Formation of partial differential equations by eliminating arbitrary functions
Formation of partial differential equations by eliminating arbitrary functionsFormation of partial differential equations by eliminating arbitrary functions
Formation of partial differential equations by eliminating arbitrary functions
Dr. Boddu Muralee Bala Krushna
 
Probability and Random Variables
Probability and Random VariablesProbability and Random Variables
Probability and Random Variables
Subhobrata Banerjee
 
DESIGN AND ANALYSIS OF ALGORITHMS
DESIGN AND ANALYSIS OF ALGORITHMSDESIGN AND ANALYSIS OF ALGORITHMS
DESIGN AND ANALYSIS OF ALGORITHMS
Gayathri Gaayu
 
complex variable PPT ( SEM 2 / CH -2 / GTU)
complex variable PPT ( SEM 2 / CH -2 / GTU)complex variable PPT ( SEM 2 / CH -2 / GTU)
complex variable PPT ( SEM 2 / CH -2 / GTU)
tejaspatel1997
 
The Importance of English Communication in Education
The Importance of English Communication in EducationThe Importance of English Communication in Education
The Importance of English Communication in Education
Intelligence Vidyarthi
 
Introduction to c++
Introduction to c++Introduction to c++
Introduction to c++
somu rajesh
 
Cauchy Eular Differential Equation
Cauchy Eular Differential EquationCauchy Eular Differential Equation
Cauchy Eular Differential Equation
FahadAhmed116
 
Laws of boolean algebra
Laws of boolean algebraLaws of boolean algebra
Laws of boolean algebra
ArunaDevi63
 
Toc 1 | gate | Theory of computation
Toc 1 | gate | Theory of computationToc 1 | gate | Theory of computation
Toc 1 | gate | Theory of computation
narayan dudhe
 
Lab manual of C++
Lab manual of C++Lab manual of C++
Lab manual of C++
thesaqib
 
Quantum mechanics for Engineering Students
Quantum mechanics for Engineering StudentsQuantum mechanics for Engineering Students
Quantum mechanics for Engineering Students
Praveen Vaidya
 
5. lec5 curl of a vector
5. lec5 curl of a vector5. lec5 curl of a vector
5. lec5 curl of a vector
shabdrang
 
08 decrease and conquer spring 15
08 decrease and conquer spring 1508 decrease and conquer spring 15
08 decrease and conquer spring 15
Hira Gul
 
The vector or cross product
The vector or cross productThe vector or cross product
The vector or cross product
Sabir Ahmed
 
Formation of partial differential equations by eliminating arbitrary functions
Formation of partial differential equations by eliminating arbitrary functionsFormation of partial differential equations by eliminating arbitrary functions
Formation of partial differential equations by eliminating arbitrary functions
Dr. Boddu Muralee Bala Krushna
 
Probability and Random Variables
Probability and Random VariablesProbability and Random Variables
Probability and Random Variables
Subhobrata Banerjee
 
DESIGN AND ANALYSIS OF ALGORITHMS
DESIGN AND ANALYSIS OF ALGORITHMSDESIGN AND ANALYSIS OF ALGORITHMS
DESIGN AND ANALYSIS OF ALGORITHMS
Gayathri Gaayu
 
complex variable PPT ( SEM 2 / CH -2 / GTU)
complex variable PPT ( SEM 2 / CH -2 / GTU)complex variable PPT ( SEM 2 / CH -2 / GTU)
complex variable PPT ( SEM 2 / CH -2 / GTU)
tejaspatel1997
 

Similar to Assignment operators (20)

Session03 operators
Session03 operatorsSession03 operators
Session03 operators
HarithaRanasinghe
 
Programming C Part 02
Programming C Part 02Programming C Part 02
Programming C Part 02
Raselmondalmehedi
 
11operator in c#
11operator in c#11operator in c#
11operator in c#
Sireesh K
 
Lecture 2 C++ | Variable Scope, Operators in c++
Lecture 2 C++ | Variable Scope, Operators in c++Lecture 2 C++ | Variable Scope, Operators in c++
Lecture 2 C++ | Variable Scope, Operators in c++
Himanshu Kaushik
 
Python operators part2
Python operators part2Python operators part2
Python operators part2
Vishal Dutt
 
Constructor and destructors
Constructor and destructorsConstructor and destructors
Constructor and destructors
divyalakshmi77
 
Operators in C#
Operators in C#Operators in C#
Operators in C#
anshika shrivastav
 
itft-Operators in java
itft-Operators in javaitft-Operators in java
itft-Operators in java
Atul Sehdev
 
Bit shift operators
Bit shift operatorsBit shift operators
Bit shift operators
alldesign
 
Opeartor &amp; expression
Opeartor &amp; expressionOpeartor &amp; expression
Opeartor &amp; expression
V.V.Vanniapermal College for Women
 
COA(Unit_3.pptx)
COA(Unit_3.pptx)COA(Unit_3.pptx)
COA(Unit_3.pptx)
Thapar Institute
 
Operators and Expression
Operators and ExpressionOperators and Expression
Operators and Expression
shubham_jangid
 
C programming(Part 1)
C programming(Part 1)C programming(Part 1)
C programming(Part 1)
Dr. SURBHI SAROHA
 
Java basic operators
Java basic operatorsJava basic operators
Java basic operators
Emmanuel Alimpolos
 
Java basic operators
Java basic operatorsJava basic operators
Java basic operators
Emmanuel Alimpolos
 
C operators
C operatorsC operators
C operators
Rupanshi rawat
 
Programming for Problem Solving
Programming for Problem SolvingProgramming for Problem Solving
Programming for Problem Solving
Sreedhar Chowdam
 
Computer programming 2 Lesson 7
Computer programming 2  Lesson 7Computer programming 2  Lesson 7
Computer programming 2 Lesson 7
MLG College of Learning, Inc
 
C - programming - Ankit Kumar Singh
C - programming - Ankit Kumar Singh C - programming - Ankit Kumar Singh
C - programming - Ankit Kumar Singh
AnkitSinghRajput35
 
Python Basic Operators
Python Basic OperatorsPython Basic Operators
Python Basic Operators
Soba Arjun
 
Ad

More from Megha Sharma (20)

Designing Printed Circuit boards, Software Choices, The Design Process
Designing Printed Circuit boards, Software Choices, The Design ProcessDesigning Printed Circuit boards, Software Choices, The Design Process
Designing Printed Circuit boards, Software Choices, The Design Process
Megha Sharma
 
Manufacturing PCB, Etching board, milling board, Third party manufacturing, a...
Manufacturing PCB, Etching board, milling board, Third party manufacturing, a...Manufacturing PCB, Etching board, milling board, Third party manufacturing, a...
Manufacturing PCB, Etching board, milling board, Third party manufacturing, a...
Megha Sharma
 
Business Model, make thing, sell thing, subscription, customization, Key Reso...
Business Model, make thing, sell thing, subscription, customization, Key Reso...Business Model, make thing, sell thing, subscription, customization, Key Reso...
Business Model, make thing, sell thing, subscription, customization, Key Reso...
Megha Sharma
 
Funding an IOT startup, Venture Capital, Government funding, Crowdfunding, Le...
Funding an IOT startup, Venture Capital, Government funding, Crowdfunding, Le...Funding an IOT startup, Venture Capital, Government funding, Crowdfunding, Le...
Funding an IOT startup, Venture Capital, Government funding, Crowdfunding, Le...
Megha Sharma
 
Sketch, Iterate and Explore, Nondigital Methods.
Sketch, Iterate and Explore, Nondigital Methods.Sketch, Iterate and Explore, Nondigital Methods.
Sketch, Iterate and Explore, Nondigital Methods.
Megha Sharma
 
CNC Milling, Software, Repurposing and Recycling.
CNC Milling, Software, Repurposing and Recycling.CNC Milling, Software, Repurposing and Recycling.
CNC Milling, Software, Repurposing and Recycling.
Megha Sharma
 
3D printing, Types of 3D printing: FDM, Laser Sintering, Powder bed, LOM, DLP.
3D printing, Types of 3D printing: FDM,  Laser Sintering,  Powder bed, LOM, DLP.3D printing, Types of 3D printing: FDM,  Laser Sintering,  Powder bed, LOM, DLP.
3D printing, Types of 3D printing: FDM, Laser Sintering, Powder bed, LOM, DLP.
Megha Sharma
 
Laser Cutting, Choosing a laser cutter, Software, Hinges and joints.
Laser Cutting, Choosing a laser cutter, Software, Hinges and joints.Laser Cutting, Choosing a laser cutter, Software, Hinges and joints.
Laser Cutting, Choosing a laser cutter, Software, Hinges and joints.
Megha Sharma
 
Memory management, Types of memory, Making the most of your RAM.
Memory management, Types of memory, Making the most of your RAM.Memory management, Types of memory, Making the most of your RAM.
Memory management, Types of memory, Making the most of your RAM.
Megha Sharma
 
Performance and Battery Life, Libraries, Debugging.
Performance and Battery Life, Libraries, Debugging.Performance and Battery Life, Libraries, Debugging.
Performance and Battery Life, Libraries, Debugging.
Megha Sharma
 
Prototyping Embedded Devices: Arduino, Developing on the Arduino.
Prototyping Embedded Devices: Arduino, Developing on the Arduino.Prototyping Embedded Devices: Arduino, Developing on the Arduino.
Prototyping Embedded Devices: Arduino, Developing on the Arduino.
Megha Sharma
 
Raspberry-Pi, Developing on Raspberry Pi, Difference between Arduino & Raspbe...
Raspberry-Pi, Developing on Raspberry Pi, Difference between Arduino & Raspbe...Raspberry-Pi, Developing on Raspberry Pi, Difference between Arduino & Raspbe...
Raspberry-Pi, Developing on Raspberry Pi, Difference between Arduino & Raspbe...
Megha Sharma
 
Open Source versus Closed Source in IOT in IOT
Open Source versus Closed Source in IOT in IOTOpen Source versus Closed Source in IOT in IOT
Open Source versus Closed Source in IOT in IOT
Megha Sharma
 
Why closed? Why Open? Mixing open and closed source
Why closed? Why Open? Mixing open and closed sourceWhy closed? Why Open? Mixing open and closed source
Why closed? Why Open? Mixing open and closed source
Megha Sharma
 
Model Performance Metrics. Accuracy, Precision, Recall
Model Performance Metrics. Accuracy, Precision, RecallModel Performance Metrics. Accuracy, Precision, Recall
Model Performance Metrics. Accuracy, Precision, Recall
Megha Sharma
 
Graceful Degradation and Affordance in IOT
Graceful Degradation and Affordance in IOTGraceful Degradation and Affordance in IOT
Graceful Degradation and Affordance in IOT
Megha Sharma
 
Web thinking connected device, Small Pieces Loosely joined.
Web thinking connected device, Small Pieces Loosely joined.Web thinking connected device, Small Pieces Loosely joined.
Web thinking connected device, Small Pieces Loosely joined.
Megha Sharma
 
Production & Mass Personalization, Changing Embedded Platform, Physical proto...
Production & Mass Personalization, Changing Embedded Platform, Physical proto...Production & Mass Personalization, Changing Embedded Platform, Physical proto...
Production & Mass Personalization, Changing Embedded Platform, Physical proto...
Megha Sharma
 
Whose data is it anyways? Public vs Private data collection.
Whose data is it anyways? Public vs Private data collection.Whose data is it anyways? Public vs Private data collection.
Whose data is it anyways? Public vs Private data collection.
Megha Sharma
 
Thinking about Prototyping: Sketching, Familiarity, Cost versus Ease of proto...
Thinking about Prototyping: Sketching, Familiarity, Cost versus Ease of proto...Thinking about Prototyping: Sketching, Familiarity, Cost versus Ease of proto...
Thinking about Prototyping: Sketching, Familiarity, Cost versus Ease of proto...
Megha Sharma
 
Designing Printed Circuit boards, Software Choices, The Design Process
Designing Printed Circuit boards, Software Choices, The Design ProcessDesigning Printed Circuit boards, Software Choices, The Design Process
Designing Printed Circuit boards, Software Choices, The Design Process
Megha Sharma
 
Manufacturing PCB, Etching board, milling board, Third party manufacturing, a...
Manufacturing PCB, Etching board, milling board, Third party manufacturing, a...Manufacturing PCB, Etching board, milling board, Third party manufacturing, a...
Manufacturing PCB, Etching board, milling board, Third party manufacturing, a...
Megha Sharma
 
Business Model, make thing, sell thing, subscription, customization, Key Reso...
Business Model, make thing, sell thing, subscription, customization, Key Reso...Business Model, make thing, sell thing, subscription, customization, Key Reso...
Business Model, make thing, sell thing, subscription, customization, Key Reso...
Megha Sharma
 
Funding an IOT startup, Venture Capital, Government funding, Crowdfunding, Le...
Funding an IOT startup, Venture Capital, Government funding, Crowdfunding, Le...Funding an IOT startup, Venture Capital, Government funding, Crowdfunding, Le...
Funding an IOT startup, Venture Capital, Government funding, Crowdfunding, Le...
Megha Sharma
 
Sketch, Iterate and Explore, Nondigital Methods.
Sketch, Iterate and Explore, Nondigital Methods.Sketch, Iterate and Explore, Nondigital Methods.
Sketch, Iterate and Explore, Nondigital Methods.
Megha Sharma
 
CNC Milling, Software, Repurposing and Recycling.
CNC Milling, Software, Repurposing and Recycling.CNC Milling, Software, Repurposing and Recycling.
CNC Milling, Software, Repurposing and Recycling.
Megha Sharma
 
3D printing, Types of 3D printing: FDM, Laser Sintering, Powder bed, LOM, DLP.
3D printing, Types of 3D printing: FDM,  Laser Sintering,  Powder bed, LOM, DLP.3D printing, Types of 3D printing: FDM,  Laser Sintering,  Powder bed, LOM, DLP.
3D printing, Types of 3D printing: FDM, Laser Sintering, Powder bed, LOM, DLP.
Megha Sharma
 
Laser Cutting, Choosing a laser cutter, Software, Hinges and joints.
Laser Cutting, Choosing a laser cutter, Software, Hinges and joints.Laser Cutting, Choosing a laser cutter, Software, Hinges and joints.
Laser Cutting, Choosing a laser cutter, Software, Hinges and joints.
Megha Sharma
 
Memory management, Types of memory, Making the most of your RAM.
Memory management, Types of memory, Making the most of your RAM.Memory management, Types of memory, Making the most of your RAM.
Memory management, Types of memory, Making the most of your RAM.
Megha Sharma
 
Performance and Battery Life, Libraries, Debugging.
Performance and Battery Life, Libraries, Debugging.Performance and Battery Life, Libraries, Debugging.
Performance and Battery Life, Libraries, Debugging.
Megha Sharma
 
Prototyping Embedded Devices: Arduino, Developing on the Arduino.
Prototyping Embedded Devices: Arduino, Developing on the Arduino.Prototyping Embedded Devices: Arduino, Developing on the Arduino.
Prototyping Embedded Devices: Arduino, Developing on the Arduino.
Megha Sharma
 
Raspberry-Pi, Developing on Raspberry Pi, Difference between Arduino & Raspbe...
Raspberry-Pi, Developing on Raspberry Pi, Difference between Arduino & Raspbe...Raspberry-Pi, Developing on Raspberry Pi, Difference between Arduino & Raspbe...
Raspberry-Pi, Developing on Raspberry Pi, Difference between Arduino & Raspbe...
Megha Sharma
 
Open Source versus Closed Source in IOT in IOT
Open Source versus Closed Source in IOT in IOTOpen Source versus Closed Source in IOT in IOT
Open Source versus Closed Source in IOT in IOT
Megha Sharma
 
Why closed? Why Open? Mixing open and closed source
Why closed? Why Open? Mixing open and closed sourceWhy closed? Why Open? Mixing open and closed source
Why closed? Why Open? Mixing open and closed source
Megha Sharma
 
Model Performance Metrics. Accuracy, Precision, Recall
Model Performance Metrics. Accuracy, Precision, RecallModel Performance Metrics. Accuracy, Precision, Recall
Model Performance Metrics. Accuracy, Precision, Recall
Megha Sharma
 
Graceful Degradation and Affordance in IOT
Graceful Degradation and Affordance in IOTGraceful Degradation and Affordance in IOT
Graceful Degradation and Affordance in IOT
Megha Sharma
 
Web thinking connected device, Small Pieces Loosely joined.
Web thinking connected device, Small Pieces Loosely joined.Web thinking connected device, Small Pieces Loosely joined.
Web thinking connected device, Small Pieces Loosely joined.
Megha Sharma
 
Production & Mass Personalization, Changing Embedded Platform, Physical proto...
Production & Mass Personalization, Changing Embedded Platform, Physical proto...Production & Mass Personalization, Changing Embedded Platform, Physical proto...
Production & Mass Personalization, Changing Embedded Platform, Physical proto...
Megha Sharma
 
Whose data is it anyways? Public vs Private data collection.
Whose data is it anyways? Public vs Private data collection.Whose data is it anyways? Public vs Private data collection.
Whose data is it anyways? Public vs Private data collection.
Megha Sharma
 
Thinking about Prototyping: Sketching, Familiarity, Cost versus Ease of proto...
Thinking about Prototyping: Sketching, Familiarity, Cost versus Ease of proto...Thinking about Prototyping: Sketching, Familiarity, Cost versus Ease of proto...
Thinking about Prototyping: Sketching, Familiarity, Cost versus Ease of proto...
Megha Sharma
 
Ad

Recently uploaded (20)

Drugs in Anaesthesia and Intensive Care,.pdf
Drugs in Anaesthesia and Intensive Care,.pdfDrugs in Anaesthesia and Intensive Care,.pdf
Drugs in Anaesthesia and Intensive Care,.pdf
crewot855
 
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFAMEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
Dr. Nasir Mustafa
 
Myopathies (muscle disorders) for undergraduate
Myopathies (muscle disorders) for undergraduateMyopathies (muscle disorders) for undergraduate
Myopathies (muscle disorders) for undergraduate
Mohamed Rizk Khodair
 
Classification of mental disorder in 5th semester bsc. nursing and also used ...
Classification of mental disorder in 5th semester bsc. nursing and also used ...Classification of mental disorder in 5th semester bsc. nursing and also used ...
Classification of mental disorder in 5th semester bsc. nursing and also used ...
parmarjuli1412
 
Cultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptxCultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptx
UmeshTimilsina1
 
What is the Philosophy of Statistics? (and how I was drawn to it)
What is the Philosophy of Statistics? (and how I was drawn to it)What is the Philosophy of Statistics? (and how I was drawn to it)
What is the Philosophy of Statistics? (and how I was drawn to it)
jemille6
 
Ajanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of HistoryAjanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of History
Virag Sontakke
 
spinal cord disorders (Myelopathies and radiculoapthies)
spinal cord disorders (Myelopathies and radiculoapthies)spinal cord disorders (Myelopathies and radiculoapthies)
spinal cord disorders (Myelopathies and radiculoapthies)
Mohamed Rizk Khodair
 
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Leonel Morgado
 
Rock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian HistoryRock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian History
Virag Sontakke
 
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon DolabaniHistory Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
fruinkamel7m
 
Form View Attributes in Odoo 18 - Odoo Slides
Form View Attributes in Odoo 18 - Odoo SlidesForm View Attributes in Odoo 18 - Odoo Slides
Form View Attributes in Odoo 18 - Odoo Slides
Celine George
 
The role of wall art in interior designing
The role of wall art in interior designingThe role of wall art in interior designing
The role of wall art in interior designing
meghaark2110
 
How to Manage Amounts in Local Currency in Odoo 18 Purchase
How to Manage Amounts in Local Currency in Odoo 18 PurchaseHow to Manage Amounts in Local Currency in Odoo 18 Purchase
How to Manage Amounts in Local Currency in Odoo 18 Purchase
Celine George
 
How to Create Kanban View in Odoo 18 - Odoo Slides
How to Create Kanban View in Odoo 18 - Odoo SlidesHow to Create Kanban View in Odoo 18 - Odoo Slides
How to Create Kanban View in Odoo 18 - Odoo Slides
Celine George
 
Overview Well-Being and Creative Careers
Overview Well-Being and Creative CareersOverview Well-Being and Creative Careers
Overview Well-Being and Creative Careers
University of Amsterdam
 
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales moduleHow To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
Celine George
 
Ancient Stone Sculptures of India: As a Source of Indian History
Ancient Stone Sculptures of India: As a Source of Indian HistoryAncient Stone Sculptures of India: As a Source of Indian History
Ancient Stone Sculptures of India: As a Source of Indian History
Virag Sontakke
 
Module 1: Foundations of Research
Module 1: Foundations of ResearchModule 1: Foundations of Research
Module 1: Foundations of Research
drroxannekemp
 
How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18
Celine George
 
Drugs in Anaesthesia and Intensive Care,.pdf
Drugs in Anaesthesia and Intensive Care,.pdfDrugs in Anaesthesia and Intensive Care,.pdf
Drugs in Anaesthesia and Intensive Care,.pdf
crewot855
 
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFAMEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
Dr. Nasir Mustafa
 
Myopathies (muscle disorders) for undergraduate
Myopathies (muscle disorders) for undergraduateMyopathies (muscle disorders) for undergraduate
Myopathies (muscle disorders) for undergraduate
Mohamed Rizk Khodair
 
Classification of mental disorder in 5th semester bsc. nursing and also used ...
Classification of mental disorder in 5th semester bsc. nursing and also used ...Classification of mental disorder in 5th semester bsc. nursing and also used ...
Classification of mental disorder in 5th semester bsc. nursing and also used ...
parmarjuli1412
 
Cultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptxCultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptx
UmeshTimilsina1
 
What is the Philosophy of Statistics? (and how I was drawn to it)
What is the Philosophy of Statistics? (and how I was drawn to it)What is the Philosophy of Statistics? (and how I was drawn to it)
What is the Philosophy of Statistics? (and how I was drawn to it)
jemille6
 
Ajanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of HistoryAjanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of History
Virag Sontakke
 
spinal cord disorders (Myelopathies and radiculoapthies)
spinal cord disorders (Myelopathies and radiculoapthies)spinal cord disorders (Myelopathies and radiculoapthies)
spinal cord disorders (Myelopathies and radiculoapthies)
Mohamed Rizk Khodair
 
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Leonel Morgado
 
Rock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian HistoryRock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian History
Virag Sontakke
 
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon DolabaniHistory Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
fruinkamel7m
 
Form View Attributes in Odoo 18 - Odoo Slides
Form View Attributes in Odoo 18 - Odoo SlidesForm View Attributes in Odoo 18 - Odoo Slides
Form View Attributes in Odoo 18 - Odoo Slides
Celine George
 
The role of wall art in interior designing
The role of wall art in interior designingThe role of wall art in interior designing
The role of wall art in interior designing
meghaark2110
 
How to Manage Amounts in Local Currency in Odoo 18 Purchase
How to Manage Amounts in Local Currency in Odoo 18 PurchaseHow to Manage Amounts in Local Currency in Odoo 18 Purchase
How to Manage Amounts in Local Currency in Odoo 18 Purchase
Celine George
 
How to Create Kanban View in Odoo 18 - Odoo Slides
How to Create Kanban View in Odoo 18 - Odoo SlidesHow to Create Kanban View in Odoo 18 - Odoo Slides
How to Create Kanban View in Odoo 18 - Odoo Slides
Celine George
 
Overview Well-Being and Creative Careers
Overview Well-Being and Creative CareersOverview Well-Being and Creative Careers
Overview Well-Being and Creative Careers
University of Amsterdam
 
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales moduleHow To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
Celine George
 
Ancient Stone Sculptures of India: As a Source of Indian History
Ancient Stone Sculptures of India: As a Source of Indian HistoryAncient Stone Sculptures of India: As a Source of Indian History
Ancient Stone Sculptures of India: As a Source of Indian History
Virag Sontakke
 
Module 1: Foundations of Research
Module 1: Foundations of ResearchModule 1: Foundations of Research
Module 1: Foundations of Research
drroxannekemp
 
How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18
Celine George
 

Assignment operators

  • 2. Assignment Operators An assignment operator is used for assigning a value to a variable. Consider A=15 Operator Description Example = Simple assignment operator. Assigns values from right side operands to left side operand C = A will assign the value of A to C i.e., C is 15 += Add AND assignment operator. It adds the right operand to the left operand and assign the result to the left operand. C += A is equivalent to C= C + A i.e., now C will be 15+15=30. -= Subtract AND assignment operator. It subtracts the right operand from the left operand and assigns the result to the left operand. C -= A is equivalent to C = C – A i.e., now C will be 30-15= 15. *= Multiply AND assignment operator. It multiplies the right operand with the left operand and assigns the result to the left operand. C *= A is equivalent to C = C * A i.e., now value of C will be 15*15= 225.
  • 3. Operator Description Example /= Divide AND assignment operator. It divides the left operand with the right operand and assigns the result to the left operand. C /= A is equivalent to C = C / A i.e., value of C will be 225/15=15 %= Modulus AND assignment operator. It takes modulus using two operands and assigns the result to the left operand. C %= A is equivalent to C = C % A i.e., value of C will be 15%5=0 <<= Left shift AND assignment operator. A <<= 2 is same as A = A << 2 i.e., value of A will be 15<<2=60 >>= Right shift AND assignment operator. A >>= 2 is same as A = A >> 2 i.e., value of A will be 60>>2=15 &= Bitwise AND assignment operator. A &= 2 is same as A= A & 2 i.e., value of A will be 15&=2 is 2 ^= Bitwise exclusive OR and assignment operator. A ^= 2 is same as A = A ^ 2 value of A will be 15^=2 is 0 |= Bitwise inclusive OR and assignment operator. A |= 2 is same as A = A | 2 value of A will be 15|=2 is 2 Continue…
  翻译: