Describe the structure of a computer system
Understand how computer languages are run on a computer system
Memory locations
The CPU
Control Bus
if (true AND false) OR (false AND true) OR NOT(false AND true) AND (true and true) OR (true OR false)
A program is written that calculates the sum of two numbers.
Name the part of the computer system that will carry out each of the following tasks during the execution of the code.
function main()
//Loops 10 times
for($i = 0; $i < 10; $i++)
print($i)
end for
end function
12 3 18 19 3 18 8 19 4 3 16 3 18 19 3 18 8 77 4 3 19 32 18 4 3 16 5 69 4 3 36 5 69 4 3 47 19 3 18 4 3 19 17 32 17 12
1100 0011 10010 10011 0011 10010 1000 10011 0100 0011 1110 0011 10010 10011 0011
Answer either high-level language or machine code for each of these:
Interpreted programs | Compiled programs |
---|---|
Report errors immediately | Report all errors after compilation |
Are slow | Are fast |
Are translated line by line | Are translated into machine code in one step |
Require an interpreter to run the program every time | Can be run independently of the compiler after compilation |
for i in range(0, 100):
print(i)
How many lines will be translated with:
A compiler?
An interpreter?
Answer the following questions:
Whiteboards task!
For each of the following answer using the keyword from the lesson!
The place where large amounts of data is stored in the computer system whilst it is running.
Random Access Memory
Reveal
Where small amount of data are stored in the CPU when a computer is running
The registers
Reveal
What ALU stands for
Arithmetic Logic Unit
Reveal
The bus where you might expect to find a memory location being transferred
Address Bus
Reveal
The computer program used to turn source code into object code in one go
A compiler
Reveal
A computer language that uses keywords from the English language
A high-level language
Reveal
Apply a filter: