0% found this document useful (0 votes)
33 views6 pages

Answer Key

Uploaded by

ktoshit1
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
33 views6 pages

Answer Key

Uploaded by

ktoshit1
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 6

Class – 9th AI & Python Self-Test Paper Answer Key

Section A: True or False (1 Mark each)

1. True - Artificial Intelligence enables machines to mimic human


behavior.
2. True - Python is a case-sensitive programming language.
3. True - The AI project cycle consists of five stages.
4. False - Python supports the use of loops.
5. False - AI systems can be trained using both supervised and
unsupervised learning methods.
6. False - The if statement in Python is used for conditional
statements, not loops.
7. True - Machine learning is a subset of artificial intelligence.
8. True - A DataFrame is a Python construct used to store multiple
pieces of data in a tabular format.
9. True - AI models can improve over time using new data.
10. False - Comments in Python start with a hash #, not double
slashes //.

Section B: Multiple Choice Questions (MCQs) (1 Mark


each)

1. b) Artificial Intelligence
2. d) main
3. c) for i in range(10):
4. b) Data Acquisition
5. a) .py
6. d) Sorting emails as spam or not spam
7. b) input()
8. b) Creating algorithms to solve problems
9. a) HelloWorld
10. b) Problem Scoping
Section C: Short Answer Questions (3 Marks each)

1. Define Artificial Intelligence in your own words.


Artificial Intelligence refers to the development of computer
systems that can perform tasks typically requiring human
intelligence, such as learning, reasoning, problem-solving, and
decision-making.
2. List any three applications of AI in real life.
o Virtual assistants (e.g., Siri, Alexa)
o Autonomous vehicles (self-driving cars)
o Predictive analytics in healthcare
3. Write a Python program to print the first 5 natural numbers
using a loop.

python

for i in range(1, 6):


print(i)

4. Explain the importance of the "Problem Scoping" stage in


the AI project cycle.
Problem scoping helps define the problem, identify the data
required, and determine the goals of the AI system. It sets the
foundation for the rest of the project, ensuring that the problem
is understood and addressed properly.
5. Differentiate between supervised and unsupervised learning.
o Supervised Learning: The model is trained on labeled
data, where the output is known.
o Unsupervised Learning: The model is trained on
unlabeled data, and it tries to identify patterns or clusters
in the data.
6. What is Python? Mention any two features of Python.
Python is a high-level, interpreted programming language
known for its readability and simplicity.
Features:
o Easy syntax and readability
o Large standard library
7. Explain the role of data in AI and why it is crucial for
modeling.
Data serves as the foundation for AI systems. It is used to train
models, validate their performance, and test their accuracy.
Without proper data, AI models cannot learn or make accurate
predictions.
8. What is the use of indentation in Python?
Indentation is used in Python to define code blocks. It indicates
the grouping of statements and is essential for proper code
structure, especially in loops, conditionals, and functions.
9. Write the output of the following code:

python

x = 10
y = 5
print(x + y)
print(x * y)

Output:

15
50

10. What is the purpose of the print() function in Python?


The print() function is used to display output to the console or
screen. It helps in debugging and showing results to the user.

Section D: Long Answer Questions (5 Marks each)

1. Explain the five stages of the AI project cycle with examples.


o Problem Scoping: Define the problem and goals (e.g.,
predicting house prices).
o Data Acquisition: Collect relevant data (e.g., historical
house prices, area).
o Modeling: Create algorithms to learn from data (e.g.,
linear regression).
o Evaluation: Assess the model's performance (e.g., using
accuracy or error rates).
o Deployment: Implement the model for use in real-world
scenarios (e.g., predicting future house prices).
2. Write a Python program to find whether a number entered
by the user is even or odd.

python

num = int(input("Enter a number: "))


if num % 2 == 0:
print("Even")
else:
print("Odd")

3. Discuss three key differences between Artificial Intelligence


and traditional programming.
o Learning vs. Rule-based: AI systems learn from data,
while traditional programming uses predefined rules.
o Adaptability: AI can improve with more data, while
traditional programming requires manual updates.
o Complexity: AI can handle complex problems with
multiple variables, while traditional programming
handles simpler tasks with known solutions.
4. Describe how AI is transforming education and healthcare
sectors.
o Education: AI enables personalized learning through
adaptive learning systems, automated grading, and AI
tutors.
o Healthcare: AI is used for diagnostic systems, treatment
recommendations, and predicting patient outcomes.
5. Write a Python program to calculate the factorial of a
number using a loop.

python

num = int(input("Enter a number: "))


factorial = 1
for i in range(1, num + 1):
factorial *= i
print(f"The factorial of {num} is {factorial}")

6. Explain with examples the different types of machine


learning.
o Supervised Learning: The model is trained with labeled
data. Example: Email spam classification.
o Unsupervised Learning: The model finds patterns in
unlabeled data. Example: Customer segmentation.
o Reinforcement Learning: The model learns by
interacting with an environment and receiving feedback.
Example: Game AI.
7. What are variables in Python? Write a program to swap the
values of two variables.
Variables are containers used to store data in Python.

python

a = 5
b = 10
a, b = b, a
print("a =", a)
print("b =", b)

8. Discuss the ethical considerations in Artificial Intelligence


development.
o Bias: AI models should be trained on unbiased data to
avoid discriminatory outcomes.
o Privacy: AI systems must respect user privacy and data
protection laws.
o Accountability: Developers must ensure AI decisions
are explainable and transparent.
9. Write a Python program to find the largest number in a list
of numbers entered by the user.

python
numbers = [int(x) for x in input("Enter numbers
separated by spaces: ").split()]
largest = max(numbers)
print(f"The largest number is {largest}")

10. How is data visualized in the AI project cycle, and why is it


important?
Data visualization helps to understand patterns, trends, and
anomalies in data. It is essential in the evaluation stage to
assess model performance and make data-driven decisions.
Common visualizations include graphs, charts, and heatmaps.

You might also like