+ 2

How can I get the complement of a number in C++?

4th Mar 2017, 7:35 AM
Nash
Nash - avatar
3 Antworten
+ 8
int x; cin >> x; cout << 90 - x
4th Mar 2017, 8:05 AM
Chirag Bhansali
Chirag Bhansali - avatar
+ 5
int x = 42; int compliment = 90-x
4th Mar 2017, 7:57 AM
Chirag Bhansali
Chirag Bhansali - avatar
+ 2
I mean the complement of a number tht is entered by the user
4th Mar 2017, 7:59 AM
Nash
Nash - avatar