+ 1

Can someone explain this

int c=9; cout<<c++; cout<<++c; What would be the possible answer

13th Jul 2021, 7:44 AM
Navneet Thakur
Navneet Thakur - avatar
2 Answers
+ 8
Navneet Thakur , i would recommend to add some additional outputs to see what happens: int c=9; cout<<c++<<endl; cout<<c<<endl; cout<<++c<<endl; cout<<c; â–Șincrementing "++"or decrementing "- -" can be done before the number is used or after the number is used. incrementing is done here with a step of 1. if you have further questions just come back and ask. happy coding
13th Jul 2021, 9:13 AM
Lothar
Lothar - avatar
+ 3
Try it on code playground.This type of question has been asked many times if you use the search bar you will find .
13th Jul 2021, 8:01 AM
The future is now thanks to science
The future is now thanks to science - avatar