+ 1
Please TELL ME THAT WHAT IS ++ SIGN FOR IN 5++ AND ++5 or. In 5-- and--5
Please tell me I am not understanding
14 Answers
+ 5
++ means you add 1 to the value in front/behind of it, -- does the opposite.
Example:
int x = 5;
x--; //x Will become 4
x++; //x will become 5 again
+ 5
Okay, here is an example for your next question:
int x = 5;
x += 5; //x Will become 10. Why? x += 5 actually means x = x + 5 --> x = 5 + 5 = 10. It's some sort of 'shortcut'.
+ 4
This is most asked question on this site. Just use 'search' function provided here
+ 1
thanks a lot friends
+ 1
I am new to this
+ 1
5+=6++ means
5+=6
5=5+6
11
+ 1
nice doubt....
these questions are comes from increment and decrement...
++5 means first increase by 1 then answers is 6.
--5 first decrease by 1 then answers is 4.
0
please also tell me that wat is this for 5+=6++
0
can any one please help me with this problem?i have studied all the concepts in c and c++, almost all the concepts but when a program,slightly difficult program is asked i dont know how to implement this concepts and where to implement it? please give me a solution.
0
this is post and pre increment operation