Self and __init__() method in Python | Python Tutorials for Beginners

แชร์
ฝัง
  • เผยแพร่เมื่อ 29 ม.ค. 2025

ความคิดเห็น • 69

  • @Chris-vt6nl
    @Chris-vt6nl 10 หลายเดือนก่อน +14

    There are several teachers who complicate even simple topics and make it hard to learn along with personally insulting students not able to understand programming,crippling their confidence saying they will never be able to understand programming😡but a teacher like you makes even a very hard topic easy to understand which is what great teaching is all about. In my school and college wish there was a teacher like you if it was so I'd have been in a wonderful position in software industry!!plz upload a video explaining decorators,generators,metaclasses,concurrency and parallelism

  • @tvsekhar6788
    @tvsekhar6788 11 หลายเดือนก่อน +5

    Thanks!

  • @souritranandy6270
    @souritranandy6270 10 หลายเดือนก่อน +7

    I have searched a lot of contents to understand OOPS in python....but i was not able to understand their explanations....but today I am getting all the concepts.... mam you are great......your explanation is crystal clear...Thank you so much mam

  • @tvsekhar6788
    @tvsekhar6788 11 หลายเดือนก่อน +3

    "Your Python videos have been a game changer for my learning journey. Thanks for making complex topics accessible and enjoyable!"

  • @justinenjau7936
    @justinenjau7936 4 หลายเดือนก่อน +1

    I have never seen a great trainer like you. You are the best. Thanks a lot

  • @shaileshbhat93
    @shaileshbhat93 ปีที่แล้ว +13

    you are making me to love python programming maam.. Thanks for your amazing teaching maam

  • @ronterambabu8153
    @ronterambabu8153 ปีที่แล้ว +3

    00:02 Discussing the __init__() method and adding attributes to a class in Python.
    02:10 Classes in Python are user-defined data types with a blueprint to create objects
    04:17 Using classes and __init__ method to store attributes for different instructors
    06:38 Constructor in Python initializes data members when an object is created
    08:47 The __init__() method initializes object attributes in Python.
    11:05 Understanding the self and __init__() method in Python
    13:31 The self and __init__() method in Python is used to initialize objects and bind attributes to arguments.
    15:45 Using default parameter values in Python for class attributes
    Crafted by Merlin AI.

  • @rajeshreddy7873
    @rajeshreddy7873 ปีที่แล้ว +8

    class CarDesign:
    pass
    cardesign_1=CarDesign()
    cardesign_2=CarDesign()
    print(type(cardesign_1))
    print(type(cardesign_2))

  • @MrShrikantpattar
    @MrShrikantpattar 3 หลายเดือนก่อน

    simple way of explaining things whithout confusing and hiding the concepts, very good , keep going, expecting more videos on core concepts of python and web design.

  • @saisuba2698
    @saisuba2698 ปีที่แล้ว +1

    I really really loved ur video because of ur examples ❤....i have zero knowledge in program but i switch my job in IT ... that's why i studying python now......in py everything is an object but class?u said one ex idly maker❤..... Thanks alottttt mam❤❤

  • @HistoricalDrammas
    @HistoricalDrammas หลายเดือนก่อน

    this is my 5th lacture about instrucroe and did not understood.but now i am fully understood. thank u a lot

  • @AnandSingh-mi3sv
    @AnandSingh-mi3sv 11 หลายเดือนก่อน +1

    Your classes have crystal clear and simple explanation which is highly appreciated...
    Just a small correction (not at all to demotivate) "self" is not keyword, instead of self we can use any word, but users are recommended to use "self" since it's common most spoken term in python dev community.

    • @jjjmemes420
      @jjjmemes420 6 หลายเดือนก่อน

      Bro how u know this ???

  • @abhilash0122
    @abhilash0122 10 หลายเดือนก่อน +5

    self is not a keyword.
    a self is an implicit object that contains the address of the current object.

  • @alokdubey4085
    @alokdubey4085 ปีที่แล้ว +1

    I saw numerous videos to understand __init__ method and self, then came across PyLenin videos, got some idea and then finally saw this video and it has become crystal clear now, thank you so much for this brilliant video, can you tell which IDE you are using, is it IntelliJ. I use Jupyter Notebook but there I don't get the hint and color differentiation.

  • @tamerlanaskarov5538
    @tamerlanaskarov5538 8 หลายเดือนก่อน

    Appreciate your work! Great Explanation!

  • @flipdruid
    @flipdruid 9 หลายเดือนก่อน

    Thank you, I keep learning and learning. Very clear explanation and understandable.

  • @Kritik-b5t
    @Kritik-b5t 16 วันที่ผ่านมา

    Mam are you from Gurgoan? Actually I am from Manipur right now I am in Gurgoan 😊.You teaching style is too helpful to me

  • @akulakalyanram4288
    @akulakalyanram4288 10 หลายเดือนก่อน

    Very good content ❤

  • @johnkamau9580
    @johnkamau9580 7 หลายเดือนก่อน

    Your voice usually gets me 🥺 when are you visiting this great country kenya😍

  • @sarveshpawar4286
    @sarveshpawar4286 ปีที่แล้ว +5

    Hello mam it's a highly request please make a video in embedded system how it works , where to use how to master and what are scopes for it how to adapt it please make video on it 😊

  • @Classsssiccontent
    @Classsssiccontent ปีที่แล้ว

    13:02 Madamji maan gaye , bahut hi badhiya sikhaya hai aaapne

  • @JuniorVasquez1
    @JuniorVasquez1 ปีที่แล้ว

    Thanks alot :)! alot easier to understand compared to other regarding this topic.

  • @white-hat666
    @white-hat666 5 หลายเดือนก่อน +1

    class Instructor:
    def __init__(self,name,address):
    self.name=name
    self.address=address
    instructor_1=Instructor("Akshu","Hyd")
    print(instructor_1.name,instructor_1.address)
    instructor_2=Instructor("Chinnu","Vizag")
    print(instructor_2.name,instructor_2.address)

  • @VivekChoudhary-dl2ji
    @VivekChoudhary-dl2ji ปีที่แล้ว

    Amazing Video.

  • @azarudeena6467
    @azarudeena6467 10 หลายเดือนก่อน +1

    class CarDesign:
    def __init__(self,name,color,model):
    self.name = name
    self.color = color
    self.model = model
    car1 = CarDesign("Thar","Black","1500CC")
    car2 = CarDesign("Fortuner","white","3000cc")

  • @futureboy8034
    @futureboy8034 ปีที่แล้ว +3

    Love from my side for giving beautiful and best contain 💌

  • @Classsssiccontent
    @Classsssiccontent ปีที่แล้ว

    Thaank youji for this lecture. Pl take sql also. Shree raaam be always be with you.

  • @user_shivshakti_1111
    @user_shivshakti_1111 ปีที่แล้ว

    Thank you Mam.

  • @rahulatal1816
    @rahulatal1816 8 หลายเดือนก่อน

    Madam pls guide for major difference between __new__ and __init__
    If __init__ is also a auto-constructor and initializer then why we use __new__
    What is the benefit of using __new__ and what problem we face if we
    Do not use __new__

  • @GaneshUmmadi-w6n
    @GaneshUmmadi-w6n 3 วันที่ผ่านมา

    why do we have to use self in this? Why can't we pass attributes directly into the class or methods like in static_method?

  • @ebubechukwuuchechukwu6018
    @ebubechukwuuchechukwu6018 3 หลายเดือนก่อน

    I wish you taught me every subject,😅

  • @shayaanshaikh104
    @shayaanshaikh104 ปีที่แล้ว

    hello mam.after completing the program plz zoom out screen,so we can note down properly

  • @EngrMuaaz
    @EngrMuaaz หลายเดือนก่อน

    class InstructorInfo:
    def __init__(self,instructor_name,address,subject):
    self.name=instructor_name
    self.address=address
    self.subject=subject
    instructor_1=InstructorInfo('Jenny','Punjab','Computer')
    print(f"{instructor_1.name}, {instructor_1.address}, {instructor_1.subject}")
    instructor_2=InstructorInfo('Payal','Delhi','Science')
    print(f"{instructor_2.name}, {instructor_2.address}, {instructor_2.subject}")

  • @kashifkhan1420
    @kashifkhan1420 ปีที่แล้ว +2

    how many more video of python you have more

  • @reverbism
    @reverbism ปีที่แล้ว +1

    If you are watching this video and even you are not interested in Python then hit that like button. we are same

  • @edutechz
    @edutechz ปีที่แล้ว +1

    Mam i love you❤️
    Cool as a teacher ❤

  • @kashifkhan1420
    @kashifkhan1420 ปีที่แล้ว +1

    when will be the course end how many more video

  • @GokulBG-pu3yu
    @GokulBG-pu3yu ปีที่แล้ว +1

    Hello mam do you have any idea about react or angular tutorial.

  • @Bhargavi-k9k
    @Bhargavi-k9k ปีที่แล้ว +1

    Mam do on java classes for degree pls mam

  • @darktv777
    @darktv777 ปีที่แล้ว

    You are looking so cool ao i reads with you ❤

  • @sravankumar1767
    @sravankumar1767 ปีที่แล้ว

    Nice explanation 👌 👍 👏, and you are So gorgeous 😍 ❤

  • @enejivik
    @enejivik ปีที่แล้ว +1

    class Instructor:
    def __init__(self, instructor_name, address):
    self.name = instructor_name
    self.address = address

    Instructor1=Instructor("victor", "market road")
    Instructor2=Instructor("David", "hostel writing code")

    print("Address: {}".format(Instructor1.address))
    print("Name: {}".format(Instructor1.name))

    print("Address: {}".format(Instructor2.address))
    print("name: {}".format(Instructor2.name))

  • @naveen_divine
    @naveen_divine ปีที่แล้ว

    😍💗

  • @shortx11
    @shortx11 ปีที่แล้ว

    #1
    class carDesign:
    pass
    obj_1 = Cardesign()
    boj_2 = CarDesign()
    print(type(obj_1))
    print(type(obj_2))

  • @thanujabantanur5113
    @thanujabantanur5113 ปีที่แล้ว +1

    Mam l need about standard deviation and varience theory information plz one help

  • @publicknowledge4241
    @publicknowledge4241 ปีที่แล้ว

    Ma'am thank you so much...I have search alots on TH-cam but you explain in very easy way...❤❤

  • @tushantmishra1482
    @tushantmishra1482 ปีที่แล้ว

    its like structure in c right?

  • @irannaroyalroy
    @irannaroyalroy ปีที่แล้ว

    Super teaching all the way from Karnataka

  • @boinidipushpalatha5750
    @boinidipushpalatha5750 ปีที่แล้ว

    How many more videos it take to complete this course?mam

  • @avnish6492
    @avnish6492 ปีที่แล้ว

    literally ,you are just awesome ..MAM
    the way you teach, no one gonna be
    yeah actually i find some error in your english but its ok
    agar madam esi ho toh sab chalega

  • @shashankmishra6129
    @shashankmishra6129 ปีที่แล้ว +1

    Numpy bta dijiye please?next video me

  • @yagnavalki3376
    @yagnavalki3376 6 หลายเดือนก่อน +1

    class Instructor:
    def __ init __(self ,instructor _name, address):
    self .name =instructor _name
    self .address =address
    self .followers =0
    Instructor_1=Instructor("Jenny" ,"Gurgaon")
    print("The first Instructor is:")
    print(Instructor_1.name)
    print(Instructor_1.address)
    print(Instructor_1.followers)
    Instructor_2=Instructor("Yagnavalki" ,"Hyderabad")
    print("The Second Instructor is:")
    print(Instructor_2.name ,'from',Instructor_2.address ,'with followers as ',Instructor_2.followers)
    Output:-
    The first Instructor is:
    Jenny
    Gurgaon
    0
    The Second Instructor is:
    Yagnavalki from Hyderabad with followers as 0

  • @Ashwinkotturu
    @Ashwinkotturu 5 หลายเดือนก่อน

    Function call and class initialisation both look the same😅.😂i dont know why they change these syntaxes so much

  • @anurajyendhe5981
    @anurajyendhe5981 ปีที่แล้ว

    Hi ma'am
    How to installation Python in vs code please make videos on this topic

    • @dd0n396
      @dd0n396 ปีที่แล้ว

      You dont install python on vscode. If python is in your path then jt should just work

  • @dhokamemes
    @dhokamemes 9 หลายเดือนก่อน

    mam biothec walo ko mt bhula kro.. hum bhi seekhne aate hein

  • @p1nk2002
    @p1nk2002 ปีที่แล้ว

    1st viewer

  • @shayaanshaikh104
    @shayaanshaikh104 ปีที่แล้ว

    hello...your voice is very low,in video.

  • @priyanshu_khristi
    @priyanshu_khristi ปีที่แล้ว +1

    Hello ma'am can you teach in hindi?

  • @khanmalik5301
    @khanmalik5301 หลายเดือนก่อน

    Self is not a keyword mam.

  • @vamsivamsi7606
    @vamsivamsi7606 ปีที่แล้ว

    Mam notes

  • @srikanthreddy1171
    @srikanthreddy1171 ปีที่แล้ว

    Hi you look stunning I mean in a nice way

  • @nisharaval2800
    @nisharaval2800 ปีที่แล้ว

    Link for exams

  • @SaiGamingff09
    @SaiGamingff09 7 หลายเดือนก่อน

    class Instructor:
    def __init__(self,name,anime):
    self.name=name
    self.anime=anime
    self.followers=0
    Instructor_1=Instructor("luffy",'OnePieece')
    Instructor_2=Instructor("Naruto",'Naruto')
    Instructor_3=Instructor("Tanjiro",'DemonSlayer')
    Instructor_4=Instructor("Goku",'DragonBalz')
    list=[Instructor_1,Instructor_2,Instructor_3,Instructor_4]
    for data in list:
    print(data.name, ' from' ,data.anime)