Question 7: Which of the following correctly identify benefits of the getline() member function for cin over the extraction oper

来源:互联网 发布:淘宝假符咒店揭露 编辑:程序博客网 时间:2024/05/16 07:32

A. The getline() function by default, accepts whitespace, and returns on seeing the /n character, whereas the extraction operator returns when it encounters any whitespace character.

    B. Delimiters indicating end of input can be specified to the getline() function, whereas the extraction operator has no such facility.

    C. The getline() function can be overloaded to accept different argument types, whereas the extraction operator cannot be overloaded.

    D. The number of bytes to read can be specified to the getline() function, whereas it cannot be done with the extraction operator.

    E. The getline() function can be used like a manipulator with cin, whereas the extraction operator cannot be used as a manipulator.

 

 

A B D