Can anyone please tell what this does and how we got this output? | Sololearn: Learn to code for FREE!

+3

Can anyone please tell what this does and how we got this output?

https://code.sololearn.com/cMQ7whO9jj2f/?ref=app

12/6/2021 12:17:55 PM

Learner🎖

4 Answers

New Answer

+2

It just printing i value i and +i are here same -2 and +(-2)=-2 finally -2 and -2 only.. Line no:5 has no effect..

+2

Thank you Jayakrishna🇮🇳

+2

Adding to Jayakrishna https://en.cppreference.com/w/cpp/language/operator_arithmetic#Unary_arithmetic_operators

+1

Hope it clears... You're welcome..