CBSE Class 12 Computer Science Question 21 of 101

Functions — Question 1

Back to all questions
1
Question

Question 1

A function in Python begins with which keyword?

  1. void
  2. return
  3. int
  4. def
Answer

def

Reason — Functions in Python are defined as per the following format :

def function_name(parameters):
    statements

According to this format, function definition begins with keyword def.