Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Write a program to find out the name of an object in python.

Answer Posted / chaitanya

The object doesn’t have any name and there is no way the can be found out for objects. The assignment is used to bind a name to the value that includes the name of the object that has to be bound by a value. If the value is callable then the statements are made true and then the program followed can be used to find the reference name of an object.

class try:

pass

B = A

a = B()

b = a

print b

<__main__.try instance at 0x16D07CC>

print b

The class consists of name and the names are invoked by using the the variable B that creates an instance for the class try. The method is to find out from all the namespaces that the object exists and then print the name of the object.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the differences between the threading and multiprocessing in python?

956


What is frozen set in python 3?

853


Explain a few methods to implement functionally oriented programming in python?

885


Consider multiple inheritances here. Suppose class c inherits from classes a and b as class c(a,b). Classes a and b both have their own versions of method func(). If we call func() from an object of class c, which version gets invoked?

1127


How can I find methods or attributes of an object in Python?

869


What does len () do in python?

924


Do they know a tuple/list/dict when they see it?

951


Does python use ram?

807


What is the difference between range and xrange functions?

882


Can __ init __ return value?

853


Can I learn python in a month?

825


What is a lambda in programming?

849


What is a python mixin?

902


How do I run a python script?

999


How do you make 3d plots/visualizations using numpy/scipy?

904