C augmented assignment operators 🧮
Bro Code Bro Code
2.2M subscribers
31,046 views
1.2K

 Published On Aug 21, 2021

C augmented assignment operators compund assignment tutorial example explained

#C #augmented #assignment

// augmented assignment operators = used to replace a statement where an operator
// takes a variable as one of its arguments
// and then assigns the result back to the same variable
// x = x + 1
// x+=1

int x = 10;

//x = x + 2;
//x+=2;

//x = x - 3;
//x-=3;

//x = x * 4;
//x*=4;

//x = x / 5;
//x/=5;

//x = x % 2;
//x%=2;

printf("%d", x);

return 0;

show more

Share/Embed