View Single Post
  #1 (permalink)  
Old July 13th, 2004, 11:31 PM
Gubber Gubber is offline
Registered User
 
Join Date: Jul 2004
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to Gubber
Default more getline problmes

#include <iostream>
#include <cstdlib>
#include <string>

using namespace std;

int main()
{
    string words, dummy;
    int borb;

    cout << "Enter Input: ";
    getline(cin, words);
    cin >> borb;

    cout << words << endl;

    return 0;
}

When I add the cin after the getline, it gives be problems, i have to type in more stuff and hit enter again before it ontinues on, any ideas?

Ian
Reply With Quote