Computer Science - Class 12
Chapter 14 - Functions in python

Which of the following is the use of id() function in python?

(a) Id() returns the identity of the object

(b) Every object doesn’t have a unique ID

(c) All of the mentioned

(d) None of the mentioned



The id( ) function is an in-built function which returns a unique id for the specified object. All objects in python has its own unique id.

So, the correct answer is (a).

Go Ad-free
Davneet Singh's photo - Co-founder, Teachoo

Made by

Davneet Singh

Davneet Singh has done his B.Tech from Indian Institute of Technology, Kanpur. He has been teaching from the past 14 years. He provides courses for Maths, Science, Social Science, Physics, Chemistry, Computer Science at Teachoo.