Computer Science, asked by upadhyayprincebby, 7 months ago

एक्सप्लेन द वर्किंग ऑफ शॉर्ट हैंड असाइनमेंट ऑपरेटर​

Answers

Answered by sumanmahla758
0

Answer:

Sorry I don't know answer of this question

Answered by Anonymous
3

Answer:

Prefix operator➡

Add or subtract a variable value by one. There are two types of prefix operator increment and decrement. If use in any expression or equation then first increment or decrement variable then solve related equitation with new value of related variable.

int a,b=10;

a=++b+5;

printf("A=%d\nB=%d",a,b);

Output:

A=16,B=11

Postfix Operator

Add or subtract a variable value by one. There are two types of prefix operator increment and decrement. If used in any expression or equitation then first solve equitation with current value of variable. After solve equitation change variable value by one depend on operator.

int a,b=10;

a=b++ +5;

printf("A=%d\nB=%d",a,b);

Output:➡

A=15,B=11

Ternary Operator

Assignment with condition. When there is a need to assign value to a variable with condition.

Syntax :➡

Variable=condition ? True Part : False Part

int n,m=10;

n=m>10?1:0;

n will initialize with 0 because m is not greater than 10 .

hope This is helpful for you ✔✔

Similar questions