// to divide
#include<stdio.h>
int main()
{
int a =12;
printf("%d\n",a/=2); // it simply divide a by 2
return 0;
}
// to add
#include<stdio.h>
int main()
{
int a =12;
printf("%d\n",a+=1); // it simply add 1 to a
return 0;
}
// to subtract
#include<stdio.h>
int main()
{
int a =12;
printf("%d\n",a-=5); // it simply subtract 5 from a
return 0;
}
// to multiply
#include<stdio.h>
int main()
{
int a =12;
printf("%d\n",a*=3); // it simply multiply a by 3
return 0;
}
// if i combime all error occur
#include<stdio.h>
int main()
{
int a =12;
printf("%d\n",a+=1); // it simply add 1 to a
printf("%d\n",a-=5); // it simply subtract 5 from a
printf("%d\n",a*=3); // it simply multiply a by 3
printf("%d\n",a/=2); // it simply divide a by 2
return 0;
}
Comments
Post a Comment