Search:

Type: Posts; User: ZapX.net

Search: Search took 0.00 seconds.

  1. Replies
    17
    Views
    2,273

    No, when you use cin, it stops at the first...

    No, when you use cin, it stops at the first whitespace character. If you use:

    getline(cin,input,'\n');

    It'll take a whole line of input.

    Edit: correction, I meant when you use >>
  2. Replies
    17
    Views
    2,273

    Another problem I see is, what if more than 50...

    Another problem I see is, what if more than 50 words are entered? It'd be so easy to do a buffer overflow in your program. You might want to use vectors or deques.

    I'm unsure what those scramble...
Results 1 to 2 of 2