Exam 6: Io Streams As an Introduction to Objects and Classes

arrow
  • Select Tags
search iconSearch Question
  • Select Tags

In the following function declaration, the istream object cin is called a ___________________. void outputistream& in=cin);

(Short Answer)
4.8/5
(37)

To open a file with a user supplied name, you would need to store the name in a variable. If the file name was to have no more than 20 characters in it, which would be an appropriate declaration of the file name variable?

(Multiple Choice)
4.8/5
(42)

If the name of the input file was in a variable named filename, which of the following is the correct way to open the input stream named inFile and associate it with this file?

(Multiple Choice)
4.9/5
(32)

'\n' is two characters.

(True/False)
4.8/5
(41)

Which of the following is the correct way to determine if a file stream named inFile opened correctly?

(Multiple Choice)
4.9/5
(38)

When passing a stream to a function, it must always be pass-by-__________.

(Short Answer)
4.7/5
(37)

Which of the following loop condition statements will read all the data in the file assuming that each record in the file is two integer values, and you will read the first one into a variable named intOne, and the other into intTwo?

(Multiple Choice)
4.8/5
(41)

A _____________ is a flow of characters or other data.

(Short Answer)
4.9/5
(44)

The flag to always show the decimal point in floating numbers is ios:: _________

(Short Answer)
4.9/5
(39)

You must use a width statement before each variable that you want output in a certain width

(True/False)
4.8/5
(40)

Which statement correctly opens an input stream named in_file and attaches it to a file name project.txt?

(Multiple Choice)
4.9/5
(39)

What is wrong with the following code? While ! fileIn.eof) ) { FileIn >> value; FileOut << value; }

(Multiple Choice)
4.8/5
(43)

"\n" is a ________ and '\n' is a _______________.

(Short Answer)
4.9/5
(31)

The get function reads

(Multiple Choice)
4.8/5
(38)

A value that can be turned on or off is called a ________.

(Short Answer)
4.9/5
(34)

The put function outputs

(Multiple Choice)
4.8/5
(39)

When is the external name of the file used in the program?

(Multiple Choice)
4.8/5
(31)

The formatting options that were discussed for cout do not work for output file streams.

(True/False)
4.8/5
(47)

open is a __________ function of the ofstream and ifstream class.

(Short Answer)
4.7/5
(31)

A __________ is a variable that has functions as well as data associated with it.

(Multiple Choice)
4.8/5
(37)
Showing 21 - 40 of 52
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)