💻
ICT Unit 1 Test
Grade 9 – Language Schools
Artificial Intelligence and Programming Languages
Term 1 – Unit 1 – Final Practice Test
40
Total Marks
24
Questions
20
MCQ Questions
4
Practical Questions
Before you start:
- Read every question carefully.
- Choose only one answer for each question.
- Questions 1–20 = 1 mark each.
- Questions 21–24 = 5 marks each.
- Total = 40 marks.
- Try to solve the practical code questions before checking the result.
Section A – Multiple Choice Questions
Questions 1–20 — Each question = 1 mark
1. Which step breaks a large problem into smaller, manageable parts?
2. What does pattern recognition help us identify?
3. What is the main purpose of abstraction?
4. Which of the following represents a step-by-step solution to a problem?
5. Which tool is commonly used to represent an algorithm visually?
6. What is an AI algorithm?
7. Why is data important for many AI systems?
8. A recommendation system suggests movies based on your previous choices. This is an example of:
9. Which Python data type is used to store text?
10. Which brackets are used to create a Python list?
11. What is the first index of a Python list?
12. Which statement can add an item to the end of a list?
13. Which keyword is used to define a function in Python?
14. What is the main advantage of using functions?
15. Which keyword can send a value back from a function?
16. What type of error can occur when int() receives text that is not a valid integer?
17. Which structure is used to handle selected exceptions?
18. What does input() normally return in Python?
19. Which part runs when the code inside try produces the specified exception?
20. Which approach is best when handling a known input error?
Section B – Practical Python Questions
Questions 21–24 — Each question = 5 marks
21. What will this program print?
numbers = [10, 20, 30]
print(numbers[1])
22. What is the output of this function?
def add(a, b):
return a + b
print(add(3, 4))
23. What happens if the user enters "abc"?
try:
age = int(input("Enter your age: "))
print(age)
except ValueError:
print("Invalid input")
24. Which code correctly handles an invalid integer input?
age = int(input("Age: "))
try:
age = int(input("Age: "))
except ValueError:
print("Please enter a number")
age = input.error()
except:
age = int(input())
Your Result
0 / 40
0%
—
No comments:
Post a Comment