By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
431,805 Members | 1,273 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 431,805 IT Pros & Developers. It's quick & easy.

I dont get c++ and i need help doing something that is simple

P: 2
I need to write a program the promts the user to input a decimal number and the program should then output the decimal and the corresponding integer
i don't know where to start
Sep 20 '06 #1
Share this Question
Share on Google+
3 Replies


Banfa
Expert Mod 5K+
P: 8,916
Are you familar with cin and cout?

How about printf and fgets (or gets)?
Sep 20 '06 #2

P: 2
Are you familar with cin and cout?

How about printf and fgets (or gets)?
yes but I don't know how to use them I know that that sounds alittle silly, but I need help
Sep 20 '06 #3

Banfa
Expert Mod 5K+
P: 8,916
float f;

cout << "Enter Number: "
cin >>f;
cout << "\n" << f << " <-> " << (int)f;
Sep 20 '06 #4

Post your reply

Sign in to post your reply or Sign up for a free account.