Practice Positional Arguments - 8.3.1 | 8. Advanced Python – Revision and Functions | CBSE Class 12th 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

What will be the output of student('John', 21) if the function is defined as def student(name, age)?

💡 Hint: Think about how the order of parameters matches with arguments.

Question 2

Easy

If def student(name, age) is defined, what arguments can you pass in when calling it?

💡 Hint: Remember to match the types as well.

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 is a positional argument?

  • An argument passed by keyword
  • An argument that depends on the order of parameters
  • An optional argument without meaning

💡 Hint: Remember, it's all about where it goes.

Question 2

True or False: The first argument passed to a function always matches the second parameter.

  • True
  • False

💡 Hint: Think carefully about the order!

Solve 2 more questions and get performance evaluation

Challenge Problems

Push your limits with challenges.

Question 1

Create a function that accepts three positional arguments: first_name, last_name, and age. Call this function with varying combinations of parameters to demonstrate its flexibility.

💡 Hint: Think about how you can mix and match.

Question 2

Write a Python function that takes two parameters but sets a default value for the second. Call it with only the first argument, then both arguments.

💡 Hint: What happens when you pass only the first argument?

Challenge and get performance evaluation