Quote:
Originally Posted by redhead
Or change printBin() to:
Code:
void printBin( int var ) {
int i;
for (i=11; i>=0; i--)
cout << ((var >> i) & 1);
cout << endl;
}
|
Good call. I've been programming in C for so long now I have forgotten a bunch of c++ stuff.