C arithmetic operators ➗

Your video will begin in 10
63 Views
Published
C arithmetic operators tutorial example explained

#C #arithmetic #operators

// arithmetic operators

// + (addition)
// - (subtraction)
// * (multiplication)
// / (division)
// % (modulus)
// ++ increment
// -- decrement

int x = 5;
int y = 2;

// int z = x + y;
// int z = x - y;
// int z = x * y;
// float z = x / (float) y;
// int z = x % y;
// x++;
// y--;

printf("%d", x);
printf("%d", y);

return 0;
Category
Bro Code
Tags
arithmetic, arithmetic operations, arithmetic operators in c
Be the first to comment