Edited by l0st.en.Drago, 12 May 2008 - 05:35 PM.
c++ I/O bug
Started by
l0st.en.Drago
, May 10 2008 01:36 PM
#1
Posted 10 May 2008 - 01:36 PM
#2
Posted 11 May 2008 - 09:06 PM
Try switching the 'greater than' arrows round:
Hope that helps.
cout << "This is a C++ program!";
Hope that helps.
#3
Posted 11 May 2008 - 09:33 PM
thanks
Edited by l0st.en.Drago, 12 May 2008 - 05:35 PM.
#4
Posted 12 May 2008 - 12:24 AM
If you are trying to get the users to type in 2 numbers, you need to use cin.
Hope thats what you were trying to do.
#include <iostream> using namespace std; int main(){ float num1, num2, ans; cout<<"Enter two numbers to add\n"; cin >> num1; cin >> num2; ans=num1+num2; cout<<ans<<endl; system("pause"); }
Hope thats what you were trying to do.
Similar Topics
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users