Tutorpip← About this lessonABCHide the answer keyDownload PDF
Coding · Ages 10+ · Set C
Data from a file
Scan to mark
on screen
C
Name
Date
Start Finish
Goal: 15 min
Score/ 12
Remember: A file keeps data after a program stops. A program reads it row by row.

Questions

1
Which one forgets when the program stops?
📓a saved notebook of rows⏳a value held while the program runs🗂️a saved table of data
2
📓Does a saved notebook of rows keep data after the program stops?
YesNo
3
Which one keeps its data after the program stops?
⏳a value held while the program runs📦a variable🗃️rows saved in a folder
4
Which one forgets when the program stops?
📁a file on the computer🗃️rows saved in a folder🧠a number held in memory
5
Which one forgets when the program stops?
🗂️a saved table of data📁a file on the computer🫙a box that empties at the end
6
Which one forgets when the program stops?
📦a variable🗃️rows saved in a folder📁a file on the computer
7
What does a program do with each row it reads?
⚙️use the row🔒close the file📖read a row
8
What does a program do last with a file?
🔒close the file⚙️use the row📂open the file
9
Which one keeps its data after the program stops?
⏳a value held while the program runs📁a file on the computer📦a variable
10
Which one keeps its data after the program stops?
🗂️a saved table of data📦a variable🫙a box that empties at the end
11
What does a program do after opening a file?
📖read a row🔒close the file📂open the file
12
What does a program do first with a file?
⚙️use the row📂open the file📖read a row
Scan the code at the top to mark this sheet on screenTake a photo of your answers or type them. It is marked for you automatically, and your score is kept.
Answer key · Set C
Data from a file
1a value held while the program runs
2Yes
3rows saved in a folder
4a number held in memory
5a box that empties at the end
6a variable
7use the row
8close the file
9a file on the computer
10a saved table of data
11read a row
12open the file
Mark each answer, count the right ones and write the score on the sheet.