Year 10 Computer Science: Variables and Logic Gates

Computer Science
Year 10
10 questions
~20 mins
0 views0 downloads

About This Worksheet

This worksheet explores variables and logic gates in programming, helping you understand how data and logic are used in computer systems.

Worksheet Preview

Full preview • 10 questions

Year 10 Computer Science: Variables and Logic Gates

Subject: Computer ScienceGrade: Year 10
Name:
Date:
TeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizzTeachWhizz

Untitled Worksheet

Grade Year 10
A

Questions

This worksheet explores variables and logic gates in programming, helping you understand how data and logic are used in computer systems.

Answer all questions in the spaces provided.
1.
Define a variable in programming and explain its purpose.
[3 marks]
2.
Write a simple line of code in a programming language of your choice that declares a variable called 'score' and assigns it the value 100.
[2 marks]
3.
Describe what happens in a program when a variable is reassigned a new value.
[3 marks]
4.
Complete the truth table for the AND gate with inputs A and B, and output C.
[4 marks]
ABOutput
00
01
10
11
5.
Draw a logic circuit for an OR gate using the basic logic gate symbols. Label the inputs as A and B, and the output as C.
[6 marks]
Drawing / Sketch space
6.
Explain the difference between the AND, OR, and NOT logic gates in terms of their function.
[4 marks]
7.
Identify the output of the following logic gate setup: A NOT gate takes input A, which is true; its output is connected to an AND gate along with input B, which is false. The AND gate's other input is true.
[5 marks]
8.
Sketch a simple flowchart that shows how a program might determine if a number stored in variable 'age' indicates an adult (age 18 or over).
[6 marks]
Drawing / Sketch space
9.
Write a short pseudocode snippet that uses a variable to check if a number stored in 'num' is positive, negative, or zero, and displays an appropriate message.
[5 marks]
10.
Describe a scenario where changing the value of a variable could lead to different outcomes in a program.
[4 marks]

Quick Actions

What is Remix?

Create a new worksheet based on this one. Change the grade level, topic, number of questions, or difficulty - then generate a fresh version.

  • • Change grade level (Grade 6 → Grade 7)
  • • Swap topics (Harry Potter → Macbeth)
  • • Add more questions (10 → 15)
  • • Adjust difficulty

Details

Created
1/2/2026
Updated
1/2/2026
Type
worksheet