super function in python|| explain in hindi||@codingwithsarika
Super():- The super function is used to give access to method and properties of a parent class. The super function returns an object the represents the parent class.
code:-
#Super() Function
class Emp():
def empdetail(self,id,name,Add):
self.id = id
self.name = name
self.Add = Add
Class Detail inherits Emp
class Detail(Emp):
def __init__(self, id, name, Add, Emails):
super().empdetail(id, name, Add)
self.Emails = Emails
Emp_1 = Detail(103, "Rahul", "Pune" , "RR@gmails")
print('The ID is:', Emp_1.id)
print('The Name is:', Emp_1.name)
print('The Address is:', Emp_1.Add)
print('The Emails is:', Emp_1.Emails)
Tags:-
#superfunction
#superfunctioninpython
#pythonbasicconcept
#pythontutorial
#pythoncode
#pythonprogram
#pythoncourse
#superfunctionexplaininhindi
Auf dieser Seite können Sie das Online-Video super function in python|| explain in hindi mit der Dauer stunde minuten sekunde in guter Qualität ansehen, das der Benutzer Coding With Sarika 23 November 2023 hochgeladen hat, den Link mit Freunden und Bekannten teilen, dieses Video wurde auf Youtube bereits 70 Mal angesehen und es wurde von 3 den Zuschauern gefallen. Viel Spaß beim Betrachtenden Zuschauern gefallen!