General-purpose computer

Tip: Choose Save as PDF in the print dialog to download. Use A4 paper size.

General-purpose computer

Name:
Date:
Class:

Quick Questions

Shade in the A or B circle for each question.

1. Which of these is a general-purpose computer?
A A laptop
B A microwave oven control board
2. How does a general-purpose computer do many different jobs?
A By swapping its CPU for each job
B By running different programs
3. A student can install a new web browser or game on a PC. What does this show?
A A PC is embedded because it can store files
B A PC is general-purpose because the user can add new software
4. True or false: A general-purpose computer can run a word processor, a game and a spreadsheet on the same hardware.
A True
B False
5. Which statement is correct?
A A desktop PC is designed to do many different tasks
B A desktop PC is designed to do one fixed task only

Match the Pairs

Draw a line connecting each item on the left to its match on the right.

Left columnRight column
1general-purpose computer AA general-purpose computer can run many different programs, not just one. Only running a single fixed program describes an embedded system.
2install new software Blaptop.run(browser); laptop.run(wordProcessor); laptop.run(game)
3A laptop can run many different applications, such as a browser, a word processor and a game CA computer, such as a PC or laptop, that can do many different jobs by running different programs
4A PC is general-purpose because the user can install new software to give it new functions DPC.install(videoEditor)
5A PC can only run one program, so it is a general-purpose computer EThe user CAN install new software on a laptop. This ability to add programs is what lets it do many different jobs.
6A laptop cannot get new software after it is bought, so it is general-purpose FThe user can add a new program to a general-purpose computer so it can do a new job

Definitions

general-purpose computer

Fill in the Blanks

Complete each line of code by filling in the missing parts.

1.
IF computer = "laptop" THEN generalPurpose ← ____ ENDIF
2.
FOR i ← 1 TO 3 RUN apps[i] ____ i
3.
IF userWantsApp = TRUE THEN _______ newSoftware ENDIF
4.
apps ← ["Word", "Chrome", "Game"] OUTPUT apps[_]
5.
IF computerType = "general-purpose" ____ manyFunctions ← TRUE ENDIF

Spot the Error

Shade in the letter of the line that contains an error.

Question 1
A computer = "microwave"
B apps = ["browser", "game"]
C for app in apps:
D print(computer, app)
Question 2
A apps = ["word", "game", "web"
B for app in apps:
C print("Open", app)
Question 3
A computer = "laptop"
B apps = ["web", "game", "code"]
C count = len(apps)
D print(computer, count "apps")
Question 4
A is_general = True
B can_install = False
C if is_general:
D print("Many jobs")
Question 5
A device = "PC"
B apps = 5
C if apps > 1
D print("Many functions")

Answer Key

General-purpose computer
Section A: Quick Questions
Q1
A — A laptop
Q2
B — By running different programs
Q3
B — A PC is general-purpose because the user can add new software
Q4
A — True
Q5
A — A desktop PC is designed to do many different tasks
Section B: Match the Pairs
Q1
general-purpose computer → A computer, such as a PC or laptop, that can do many different jobs by running different programs
Q2
install new software → The user can add a new program to a general-purpose computer so it can do a new job
Q3
A laptop can run many different applications, such as a browser, a word processor and a game → laptop.run(browser); laptop.run(wordProcessor); laptop.run(game)
Q4
A PC is general-purpose because the user can install new software to give it new functions → PC.install(videoEditor)
Q5
A PC can only run one program, so it is a general-purpose computer → A general-purpose computer can run many different programs, not just one. Only running a single fixed program describes an embedded system.
Q6
A laptop cannot get new software after it is bought, so it is general-purpose → The user CAN install new software on a laptop. This ability to add programs is what lets it do many different jobs.
Section C: Definitions
Q1
general-purpose computer — A computer, such as a PC or laptop, that can do many different jobs by running different programs, and the user can install new software.
Section D: Fill in the Blanks
Q1
IF computer = "laptop" THEN generalPurpose ← TRUE ENDIF
Q2
FOR i ← 1 TO 3 RUN apps[i] NEXT i
Q3
IF userWantsApp = TRUE THEN INSTALL newSoftware ENDIF
Q4
apps ← ["Word", "Chrome", "Game"] OUTPUT apps[2]
Q5
IF computerType = "general-purpose" THEN manyFunctions ← TRUE ENDIF
Section E: Spot the Error
Q1
A — A microwave is an embedded system built for one job. A general-purpose computer is a PC or laptop, so the line should be computer = "laptop".
Q2
A — The list is missing its closing square bracket. It should be apps = ["word", "game", "web"].
Q3
D — There is a comma missing between count and "apps". It should be print(computer, count, "apps").
Q4
B — On a general-purpose computer the user can install new software. So can_install should be True.
Q5
C — An if statement must end with a colon. It should be if apps > 1: