A couple questions

E

eli m

1. First off, how do i make a while loop in c++?
2. Second, what is the most basic way to get input and then assign it to a variable?
3. How do i know what type of declaration (or whatever its called) to a variable? For example: int, long, float, char, double
 
V

Victor Bazarov

1. First off, how do i make a while loop in c++?

What book on C++ are you reading that doesn't explain that?
2. Second, what is the most basic way to get input and then assign it to a variable?

cin >> variable
3. How do i know what type of declaration (or whatever its called) to a variable? For example: int, long, float, char, double

You know when you decide what it's used for. Usually *you* pick the
type, and not vice versa.

V
 
E

eli m

What book on C++ are you reading that doesn't explain that?






cin >> variable






You know when you decide what it's used for. Usually *you* pick the

type, and not vice versa.



V

Sorry, for the last one i meant when do i assign a certain decleration to a variable. Likewhen do i use double etc.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,968
Messages
2,570,150
Members
46,696
Latest member
BarbraOLog

Latest Threads

Top