In Python instance methods use __________ as first default parameter.

2023

In Python instance methods use __________ as first default parameter.

Answer: C. selfIn Python, instance methods include self as the first parameter, which represents the current object instance. It allows access to instance variables and…

  1. A.

    primary

  2. B.

    secondary

  3. C.

    self

  4. D.

    selfie

Attempted by 278 students.

Show answer & explanation

Correct answer: C

In Python, instance methods include self as the first parameter, which represents the current object instance.
It allows access to instance variables and methods, making it essential for object-oriented programming.

Explore the full course: Hpsc Pgt Computer Science

Loading lesson…