Lecture 10 Flashcards

1
Q

What are the three main steps when a program is reading or writing to a file?

A
  1. Opening the file
  2. Reading from or writing to the file
  3. Closing the file
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is the fstream library?

A

It allows you to stream to and from files and create fstream type objects.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is an object?

A

It is like a variable and can be declared and/or initialized. An object can hold more than one piece of information and can have functions that “belong” with it.

Vectors and strings are also objects

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the type of an fstream object?

A

Fstream

How well did you know this?
1
Not at all
2
3
4
5
Perfectly