Practice Defining a Function - 11.9.1 | 11. Python Programming | CBSE Class 11th AI (Artificial Intelligence)
K12 Students

Academics

AI-Powered learning for Grades 8–12, aligned with major Indian and international curricula.

Professionals

Professional Courses

Industry-relevant training in Business, Technology, and Design to help professionals and graduates upskill for real-world careers.

Games

Interactive Games

Fun, engaging games to boost memory, math fluency, typing speed, and English skills—perfect for learners of all ages.

Practice Questions

Test your understanding with targeted questions related to the topic.

Question 1

Easy

Define a function named say_hi that takes no parameters and prints Hi!.

💡 Hint: Use the 'def' keyword followed by the function name.

Question 2

Easy

Create a function named multiply that takes two numbers and prints their product.

💡 Hint: Make sure to define parameters in parentheses.

Practice 4 more questions and get performance evaluation

Interactive Quizzes

Engage in quick quizzes to reinforce what you've learned and check your comprehension.

Question 1

What keyword is used to define a function in Python?

  • def
  • function
  • define

💡 Hint: Think about the keyword that starts function definitions.

Question 2

True or False: A function can take arguments.

  • True
  • False

💡 Hint: Remember the examples we discussed involving parameters.

Solve 1 more question and get performance evaluation

Challenge Problems

Push your limits with challenges.

Question 1

Write a function find_max that accepts a list of numbers and returns the largest number. Test your function.

💡 Hint: Consider using built-in Python functions.

Question 2

Define a function factorial that computes the factorial of a number using recursion.

💡 Hint: Think about how factorial is defined mathematically.

Challenge and get performance evaluation