Deck 7: File Handling and Applications

Full screen (f)
exit full mode
Question
____ are groups of fields that go together for some logical reason.

A)Tables
B)Databases
C)Columns
D)Records
Use Space or
up arrow
down arrow
to flip the card.
Question
When you copy data from RAM into a file on a storage device, you read to the file.
Question
You update the transaction file with data from the master file.
Question
You can merge more than two files.
Question
The keyboard and printer are the default input and output devices.
Question
The terms "parent" and "child" can refer to file backup generations, but they are also used for a different purpose in object-oriented programming.
Question
To write a program that produces a report of employees by department number, the records must be grouped by department number before you begin processing.
Question
____ storage is not lost when a computer loses power.

A)Temporary
B)Intermediate
C)Permanent
D)Variable
Question
When you write a program that stores a value in a variable, you are using ____ storage.

A)permanent
B)temporary
C)resilient
D)resident
Question
Files in which records must be accessed immediately are sometimes called instant access files.
Question
____ is the more general term for an entity that organizes files.

A)Hierarchy
B)Path
C)Structure
D)Directory
Question
Programmers usually use the word "write" to mean "produce hard copy output."
Question
Images and music are contained in binary files.
Question
You can easily merge files even if each file contains a different record layout.
Question
A database holds related file data in ____ .

A)fields
B)records
C)control breaks
D)tables
Question
The combination of the disk drive plus the complete hierarchy of directories in which a file resides is its ____.

A)pointer
B)path
C)locator
D)stream
Question
A ____ is a collection of data stored on a nonvolatile device in a computer system.

A)computer message
B)computer interface
C)computer file
D)computer selector
Question
Files exist on ____ storage devices, such as hard disks, DVDs, USB drives, and reels of magnetic tape.

A)permanent
B)transient
C)scalable
D)optical
Question
Characters are made up of smaller elements called ____.

A)fields
B)records
C)bits
D)bytes
Question
Directories and ____ are organization units on storage devices.

A)folders
B)files
C)partitions
D)streams
Question
When the records in a file are sorted in order from lowest to highest values, the records are in ____ order.

A)descending
B)bubble
C)ascending
D)merged
Question
A ____ is a temporary detour in the logic of a program.

A)sequence break
B)control break
C)control sequence
D)break control
Question
A ____ is a copy that is kept in case values need to be restored to their original state.

A)read-only file
B)backup file
C)primary file
D)secondary file
Question
A ____ break is a break in the logic of the program that is based on the value of a single variable.

A)multiple-level control
B)simple control
C)serial control
D)single-level control
Question
____ applications require that a record be accessed immediately while a client is waiting.

A)Real-time
B)Batch
C)Database
D)Sort
Question
When you ____ a file, it is no longer available to your application.

A)examine
B)rewrite
C)close
D)index
Question
When a program uses a ____, it reads all the records in the file from beginning to end, processing them one at a time.

A)random access file
B)serial file
C)retired file
D)sequential file
Question
To generate a control break report, your input records must be organized in ____ order based on the field that will cause the breaks.

A)random
B)ascending
C)sequential
D)repeatable
Question
____ files involves combining two or more files while maintaining the sequential order of the records.

A)Merging
B)Sorting
C)Splitting
D)Dividing
Question
In most programming languages, before an application can use a data file, it must ____.

A)open the file
B)close the file
C)read the file
D)prepare the file
Question
Because they enable you to locate a particular record directly (without reading all of the preceding records), random access files are also called ____ files.

A)direct access
B)indirect access
C)sequential access
D)pointed access
Question
A program in which the user makes direct requests is a(n)____________________ program.
Question
When you store data in a computer file on a persistent storage device, you ____________________ to the file.
Question
When businesses store data items on computer systems, they are often stored in a framework called the data ____________________ that describes the relationships between data components.
Question
When you copy data from a file on a storage device into RAM, you are ____ from the file.

A)writing
B)uploading
C)outputing
D)reading
Question
The saved version of a master file is the ____ file; the updated version is the child file.

A)peer
B)subordinate
C)parent
D)child
Question
A(n)____________________ file holds more temporary data than a master file.
Question
A(n)____________________ is a small unit of storage that, for example, holds only one character in a simple text file.
Question
The ____ file holds temporary data that is used to update the master file.

A)directory
B)transaction
C)merge
D)database
Question
____ is processing that involves performing the same tasks with many records, one after the other.

A)Volume processing
B)Batch processing
C)Online processing
D)Standard processing
Question
Match between columns
A file in which records can be located in any order
files
A file in which records can be located in any order
kilobytes
A file in which records can be located in any order
characters
A file in which records can be located in any order
random access file
A file in which records can be located in any order
master file
A file in which records can be located in any order
megabytes
A file in which records can be located in any order
volatile storage
A file in which records can be located in any order
fields
A file in which records can be located in any order
gigabytes
A file in which records can be located in any order
nonvolatile storage
Question
What is a database?
Question
How do you merge two alphabetically ordered input files into a new output file when you wish the output file to be in alphabetical order?
Question
Define and give examples of text files and binary files.
Question
How are the keyboard and monitor used in most programming languages?
Question
What happens when you fail to close an output file?
Question
Match between columns
Holds complete and relatively permanent data
files
Holds complete and relatively permanent data
kilobytes
Holds complete and relatively permanent data
characters
Holds complete and relatively permanent data
random access file
Holds complete and relatively permanent data
master file
Holds complete and relatively permanent data
megabytes
Holds complete and relatively permanent data
volatile storage
Holds complete and relatively permanent data
fields
Holds complete and relatively permanent data
gigabytes
Holds complete and relatively permanent data
nonvolatile storage
Question
Match between columns
Groups of related records
files
Groups of related records
kilobytes
Groups of related records
characters
Groups of related records
random access file
Groups of related records
master file
Groups of related records
megabytes
Groups of related records
volatile storage
Groups of related records
fields
Groups of related records
gigabytes
Groups of related records
nonvolatile storage
Question
Match between columns
Single useful data items that are composed of one or more characters
files
Single useful data items that are composed of one or more characters
kilobytes
Single useful data items that are composed of one or more characters
characters
Single useful data items that are composed of one or more characters
random access file
Single useful data items that are composed of one or more characters
master file
Single useful data items that are composed of one or more characters
megabytes
Single useful data items that are composed of one or more characters
volatile storage
Single useful data items that are composed of one or more characters
fields
Single useful data items that are composed of one or more characters
gigabytes
Single useful data items that are composed of one or more characters
nonvolatile storage
Question
Match between columns
Letters, numbers, and special symbols, such as "A", "7", and "$"
files
Letters, numbers, and special symbols, such as "A", "7", and "$"
kilobytes
Letters, numbers, and special symbols, such as "A", "7", and "$"
characters
Letters, numbers, and special symbols, such as "A", "7", and "$"
random access file
Letters, numbers, and special symbols, such as "A", "7", and "$"
master file
Letters, numbers, and special symbols, such as "A", "7", and "$"
megabytes
Letters, numbers, and special symbols, such as "A", "7", and "$"
volatile storage
Letters, numbers, and special symbols, such as "A", "7", and "$"
fields
Letters, numbers, and special symbols, such as "A", "7", and "$"
gigabytes
Letters, numbers, and special symbols, such as "A", "7", and "$"
nonvolatile storage
Question
Describe what is required to merge more than two files.
Question
Match between columns
Billions of bytes
files
Billions of bytes
kilobytes
Billions of bytes
characters
Billions of bytes
random access file
Billions of bytes
master file
Billions of bytes
megabytes
Billions of bytes
volatile storage
Billions of bytes
fields
Billions of bytes
gigabytes
Billions of bytes
nonvolatile storage
Question
Match between columns
Millions of bytes
files
Millions of bytes
kilobytes
Millions of bytes
characters
Millions of bytes
random access file
Millions of bytes
master file
Millions of bytes
megabytes
Millions of bytes
volatile storage
Millions of bytes
fields
Millions of bytes
gigabytes
Millions of bytes
nonvolatile storage
Question
List and describe three characteristics that all files have in common.
Question
Explain the difference in how programmers use the words print , write , and display .
Question
Why might programmers use a control break program?
Question
Match between columns
Thousands of bytes
files
Thousands of bytes
kilobytes
Thousands of bytes
characters
Thousands of bytes
random access file
Thousands of bytes
master file
Thousands of bytes
megabytes
Thousands of bytes
volatile storage
Thousands of bytes
fields
Thousands of bytes
gigabytes
Thousands of bytes
nonvolatile storage
Question
What does the term batch processing mean?
Question
Match between columns
Is lost when the program ends or the computer loses power
files
Is lost when the program ends or the computer loses power
kilobytes
Is lost when the program ends or the computer loses power
characters
Is lost when the program ends or the computer loses power
random access file
Is lost when the program ends or the computer loses power
master file
Is lost when the program ends or the computer loses power
megabytes
Is lost when the program ends or the computer loses power
volatile storage
Is lost when the program ends or the computer loses power
fields
Is lost when the program ends or the computer loses power
gigabytes
Is lost when the program ends or the computer loses power
nonvolatile storage
Question
Match between columns
Is not lost when a computer loses power
files
Is not lost when a computer loses power
kilobytes
Is not lost when a computer loses power
characters
Is not lost when a computer loses power
random access file
Is not lost when a computer loses power
master file
Is not lost when a computer loses power
megabytes
Is not lost when a computer loses power
volatile storage
Is not lost when a computer loses power
fields
Is not lost when a computer loses power
gigabytes
Is not lost when a computer loses power
nonvolatile storage
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/60
auto play flashcards
Play
simple tutorial
Full screen (f)
exit full mode
Deck 7: File Handling and Applications
1
____ are groups of fields that go together for some logical reason.

A)Tables
B)Databases
C)Columns
D)Records
D
2
When you copy data from RAM into a file on a storage device, you read to the file.
False
3
You update the transaction file with data from the master file.
False
4
You can merge more than two files.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
5
The keyboard and printer are the default input and output devices.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
6
The terms "parent" and "child" can refer to file backup generations, but they are also used for a different purpose in object-oriented programming.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
7
To write a program that produces a report of employees by department number, the records must be grouped by department number before you begin processing.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
8
____ storage is not lost when a computer loses power.

A)Temporary
B)Intermediate
C)Permanent
D)Variable
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
9
When you write a program that stores a value in a variable, you are using ____ storage.

A)permanent
B)temporary
C)resilient
D)resident
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
10
Files in which records must be accessed immediately are sometimes called instant access files.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
11
____ is the more general term for an entity that organizes files.

A)Hierarchy
B)Path
C)Structure
D)Directory
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
12
Programmers usually use the word "write" to mean "produce hard copy output."
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
13
Images and music are contained in binary files.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
14
You can easily merge files even if each file contains a different record layout.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
15
A database holds related file data in ____ .

A)fields
B)records
C)control breaks
D)tables
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
16
The combination of the disk drive plus the complete hierarchy of directories in which a file resides is its ____.

A)pointer
B)path
C)locator
D)stream
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
17
A ____ is a collection of data stored on a nonvolatile device in a computer system.

A)computer message
B)computer interface
C)computer file
D)computer selector
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
18
Files exist on ____ storage devices, such as hard disks, DVDs, USB drives, and reels of magnetic tape.

A)permanent
B)transient
C)scalable
D)optical
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
19
Characters are made up of smaller elements called ____.

A)fields
B)records
C)bits
D)bytes
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
20
Directories and ____ are organization units on storage devices.

A)folders
B)files
C)partitions
D)streams
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
21
When the records in a file are sorted in order from lowest to highest values, the records are in ____ order.

A)descending
B)bubble
C)ascending
D)merged
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
22
A ____ is a temporary detour in the logic of a program.

A)sequence break
B)control break
C)control sequence
D)break control
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
23
A ____ is a copy that is kept in case values need to be restored to their original state.

A)read-only file
B)backup file
C)primary file
D)secondary file
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
24
A ____ break is a break in the logic of the program that is based on the value of a single variable.

A)multiple-level control
B)simple control
C)serial control
D)single-level control
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
25
____ applications require that a record be accessed immediately while a client is waiting.

A)Real-time
B)Batch
C)Database
D)Sort
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
26
When you ____ a file, it is no longer available to your application.

A)examine
B)rewrite
C)close
D)index
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
27
When a program uses a ____, it reads all the records in the file from beginning to end, processing them one at a time.

A)random access file
B)serial file
C)retired file
D)sequential file
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
28
To generate a control break report, your input records must be organized in ____ order based on the field that will cause the breaks.

A)random
B)ascending
C)sequential
D)repeatable
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
29
____ files involves combining two or more files while maintaining the sequential order of the records.

A)Merging
B)Sorting
C)Splitting
D)Dividing
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
30
In most programming languages, before an application can use a data file, it must ____.

A)open the file
B)close the file
C)read the file
D)prepare the file
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
31
Because they enable you to locate a particular record directly (without reading all of the preceding records), random access files are also called ____ files.

A)direct access
B)indirect access
C)sequential access
D)pointed access
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
32
A program in which the user makes direct requests is a(n)____________________ program.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
33
When you store data in a computer file on a persistent storage device, you ____________________ to the file.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
34
When businesses store data items on computer systems, they are often stored in a framework called the data ____________________ that describes the relationships between data components.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
35
When you copy data from a file on a storage device into RAM, you are ____ from the file.

A)writing
B)uploading
C)outputing
D)reading
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
36
The saved version of a master file is the ____ file; the updated version is the child file.

A)peer
B)subordinate
C)parent
D)child
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
37
A(n)____________________ file holds more temporary data than a master file.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
38
A(n)____________________ is a small unit of storage that, for example, holds only one character in a simple text file.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
39
The ____ file holds temporary data that is used to update the master file.

A)directory
B)transaction
C)merge
D)database
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
40
____ is processing that involves performing the same tasks with many records, one after the other.

A)Volume processing
B)Batch processing
C)Online processing
D)Standard processing
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
41
Match between columns
A file in which records can be located in any order
files
A file in which records can be located in any order
kilobytes
A file in which records can be located in any order
characters
A file in which records can be located in any order
random access file
A file in which records can be located in any order
master file
A file in which records can be located in any order
megabytes
A file in which records can be located in any order
volatile storage
A file in which records can be located in any order
fields
A file in which records can be located in any order
gigabytes
A file in which records can be located in any order
nonvolatile storage
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
42
What is a database?
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
43
How do you merge two alphabetically ordered input files into a new output file when you wish the output file to be in alphabetical order?
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
44
Define and give examples of text files and binary files.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
45
How are the keyboard and monitor used in most programming languages?
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
46
What happens when you fail to close an output file?
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
47
Match between columns
Holds complete and relatively permanent data
files
Holds complete and relatively permanent data
kilobytes
Holds complete and relatively permanent data
characters
Holds complete and relatively permanent data
random access file
Holds complete and relatively permanent data
master file
Holds complete and relatively permanent data
megabytes
Holds complete and relatively permanent data
volatile storage
Holds complete and relatively permanent data
fields
Holds complete and relatively permanent data
gigabytes
Holds complete and relatively permanent data
nonvolatile storage
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
48
Match between columns
Groups of related records
files
Groups of related records
kilobytes
Groups of related records
characters
Groups of related records
random access file
Groups of related records
master file
Groups of related records
megabytes
Groups of related records
volatile storage
Groups of related records
fields
Groups of related records
gigabytes
Groups of related records
nonvolatile storage
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
49
Match between columns
Single useful data items that are composed of one or more characters
files
Single useful data items that are composed of one or more characters
kilobytes
Single useful data items that are composed of one or more characters
characters
Single useful data items that are composed of one or more characters
random access file
Single useful data items that are composed of one or more characters
master file
Single useful data items that are composed of one or more characters
megabytes
Single useful data items that are composed of one or more characters
volatile storage
Single useful data items that are composed of one or more characters
fields
Single useful data items that are composed of one or more characters
gigabytes
Single useful data items that are composed of one or more characters
nonvolatile storage
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
50
Match between columns
Letters, numbers, and special symbols, such as "A", "7", and "$"
files
Letters, numbers, and special symbols, such as "A", "7", and "$"
kilobytes
Letters, numbers, and special symbols, such as "A", "7", and "$"
characters
Letters, numbers, and special symbols, such as "A", "7", and "$"
random access file
Letters, numbers, and special symbols, such as "A", "7", and "$"
master file
Letters, numbers, and special symbols, such as "A", "7", and "$"
megabytes
Letters, numbers, and special symbols, such as "A", "7", and "$"
volatile storage
Letters, numbers, and special symbols, such as "A", "7", and "$"
fields
Letters, numbers, and special symbols, such as "A", "7", and "$"
gigabytes
Letters, numbers, and special symbols, such as "A", "7", and "$"
nonvolatile storage
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
51
Describe what is required to merge more than two files.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
52
Match between columns
Billions of bytes
files
Billions of bytes
kilobytes
Billions of bytes
characters
Billions of bytes
random access file
Billions of bytes
master file
Billions of bytes
megabytes
Billions of bytes
volatile storage
Billions of bytes
fields
Billions of bytes
gigabytes
Billions of bytes
nonvolatile storage
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
53
Match between columns
Millions of bytes
files
Millions of bytes
kilobytes
Millions of bytes
characters
Millions of bytes
random access file
Millions of bytes
master file
Millions of bytes
megabytes
Millions of bytes
volatile storage
Millions of bytes
fields
Millions of bytes
gigabytes
Millions of bytes
nonvolatile storage
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
54
List and describe three characteristics that all files have in common.
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
55
Explain the difference in how programmers use the words print , write , and display .
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
56
Why might programmers use a control break program?
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
57
Match between columns
Thousands of bytes
files
Thousands of bytes
kilobytes
Thousands of bytes
characters
Thousands of bytes
random access file
Thousands of bytes
master file
Thousands of bytes
megabytes
Thousands of bytes
volatile storage
Thousands of bytes
fields
Thousands of bytes
gigabytes
Thousands of bytes
nonvolatile storage
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
58
What does the term batch processing mean?
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
59
Match between columns
Is lost when the program ends or the computer loses power
files
Is lost when the program ends or the computer loses power
kilobytes
Is lost when the program ends or the computer loses power
characters
Is lost when the program ends or the computer loses power
random access file
Is lost when the program ends or the computer loses power
master file
Is lost when the program ends or the computer loses power
megabytes
Is lost when the program ends or the computer loses power
volatile storage
Is lost when the program ends or the computer loses power
fields
Is lost when the program ends or the computer loses power
gigabytes
Is lost when the program ends or the computer loses power
nonvolatile storage
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
60
Match between columns
Is not lost when a computer loses power
files
Is not lost when a computer loses power
kilobytes
Is not lost when a computer loses power
characters
Is not lost when a computer loses power
random access file
Is not lost when a computer loses power
master file
Is not lost when a computer loses power
megabytes
Is not lost when a computer loses power
volatile storage
Is not lost when a computer loses power
fields
Is not lost when a computer loses power
gigabytes
Is not lost when a computer loses power
nonvolatile storage
Unlock Deck
Unlock for access to all 60 flashcards in this deck.
Unlock Deck
k this deck
locked card icon
Unlock Deck
Unlock for access to all 60 flashcards in this deck.