First post, oh boy... So i finally got around to joining up. Now im checking out all that there is to do on the site. will actually update when i have time between classes
More Blogs
-
2
Sunday May 29, 2005
gah, need to get back in the habit of updating regularly.... so t… -
2
Sunday May 08, 2005
long time no update... NIN CONCERT WAS FUCKING AMAZING!!! worth e… -
3
Wednesday Apr 20, 2005
http://www.greenzap.com/anonymouspromo new paypal type service, si… -
0
Monday Apr 18, 2005
well, here's my summary of the weekend: friday: class, then work,… -
3
Tuesday Apr 12, 2005
The interview today was alright. Very relaxed environmebt. I have … -
2
Tuesday Apr 12, 2005
i've been in the mood for some crazy amount of philosophic discussion… -
4
Wednesday Apr 06, 2005
what a day.... best day of spring so far.... recap.... got laundry … -
1
Tuesday Apr 05, 2005
w00t, interview on the 12th... should rock as they told me i dont eve… -
1
Sunday Apr 03, 2005
msu lost last night's ncaa game... i dont care about sports, but what… -
4
Thursday Mar 31, 2005
holy fast response batman.... so, i already got an email back saying…
#include <iostream.h>
void binary(int);
void main(void) {
int number;
cout << "Please enter a positive integer: ";
cin >> number;
if (number < 0)
cout << "That is not a positive integer.\n";
else {
cout << number << " converted to binary is: ";
binary(number);
cout << endl;
}
}
void binary(int number) {
int remainder;
if(number <= 1) {
cout << number;
return;
}
remainder = number%2;
binary(number >> 1);
cout << remainder;
}