Knowledge Walls
Venkatesan
Hyderabad, Andhra Pradesh, India
Passcode:
Introduction [cont'd]
Input Output Functions [cont'd]
Structures and Unions [cont'd]
# Preprocessor [cont'd]
Assignment Operators in Operators of Programming in C
1949 Views
Assignment Operators 
Assignment operators are used to assign the expression result to the left hand side variable. Also support shortform of assignment operators.
Operators and meaning 
Operators General expressions Shortform with assignment operators
= a = b + 10;
+= a = a + 10; a += 10;
-= a = a - 10; a -= 10;
*= a = a * 10; a *= 10;
/= a = a / 10; a /= 10;
Program
#include
void main(){
    int a;
    a = 10;
    a += 2;
    printf("A value is %d",a);
}
Output 
A = 12
Next Topics
Next lessons of current book.
Input Output Functions of Programming in C
Input Output Functions of Programming in C
Previous Topics
Previous lessons of current book.
Best Lessons of "Programming in C"
Top lessons which are viewed more times.
Structures and Unions of Programming in C
Input Output Functions of Programming in C
Structures and Unions of Programming in C
  Copyright © 2014 Knowledge walls, All rights reserved
KnowledgeWalls
keep your tutorials and learnings with KnowledgeWalls. Don't lose your learnings hereafter. Save and revise it whenever required.
Click here for more details