Reading a string

Are any of these options valid for reading a string of 100 characters? Why/Why not are the options true/false? I tried using all of them, but none of them seem to work. I know that to use getline,the syntax is getline(cin, name), but since there is a dot operator, does it make any difference? Any help would be really helpful.
a. cin.getline(x, 100, '\n');
b. cin.getline(100, x, '\n');
c. readline(x, 100, '\n');
d. read(x);
closed account (48T7M4Gy)
but since there is a dot operator, does it make any difference?

Perhaps if you checked out both cases and then make a decision it might be the way to go.
I'm sorry, I don't get your point? I did try all of these options, but they would give me a compilation error. So I don't really know what the problem is.

P.S. This is a question from a sample paper and since these are the only options provided, one of the answers should be true?
Topic archived. No new replies allowed.