#59 Python Tutorial for Beginners | Operator Overloading | Polymorphism

  Рет қаралды 357,531

Telusko

Telusko

5 жыл бұрын

Python Tutorial to learn Python programming with examples
Complete Python Tutorial for Beginners Playlist : • #1 Python Tutorial for...
Python Tutorial in Hindi : • #1 Python Tutorial | I...
Github :- github.com/navinreddy20/Python-
Editing Monitors :
amzn.to/2RfKWgL
amzn.to/2Q665JW
amzn.to/2OUP21a.
Check out our website: www.telusko.com
Follow Telusko on Twitter: / navinreddy20
Follow on Facebook:
Telusko : / teluskolearn. .
Navin Reddy : / navintelusko
Follow Navin Reddy on Instagram: / navinreddy20
Subscribe to our other channel:
Navin Reddy : kzfaq.info/love/xmk...
Telusko Hindi :
kzfaq.info/love/itz...
Donation:
PayPal Id : navinreddy20
Patreon : navinreddy20
www.telusko.com/contactus

Пікірлер: 277
@maneeshsingh2647
@maneeshsingh2647 4 жыл бұрын
"This is horrible way to compare two students by marks" I Love this line👍🙂
@HarjotSingh-rj2lf
@HarjotSingh-rj2lf 3 жыл бұрын
ikr
@dakshsingh6033
@dakshsingh6033 2 жыл бұрын
bro i also loved it so much!! what a quencidence
@mainakchakrabarti
@mainakchakrabarti 4 жыл бұрын
Sir your statement : "marks is not the way of comparing" won my heart
@utkarshachaudhari871
@utkarshachaudhari871 4 жыл бұрын
After so so many years, I have finally understood operator overloading!
@ankitakumari2756
@ankitakumari2756 3 жыл бұрын
😱😱😇
@tanishasethi7363
@tanishasethi7363 3 жыл бұрын
Exactly
@alimdeen6921
@alimdeen6921 3 жыл бұрын
Still i can't understand operator overloading 😔😓
@anindian4601
@anindian4601 2 жыл бұрын
@@alimdeen6921 YOU ARE RIGHT, THIS GUY Showing his nose after traveling through out the universe, actually he has to tell first simple example then he can show his vaast variety of expereince on us as beginners but directly he showing something else 99.9999999% from that the thing what we need is 0.0000000001% so its very confusing he did same for duck typing also
@abhisheksriramoju8772
@abhisheksriramoju8772 2 жыл бұрын
@@anindian4601 No, Actually his explanation is cool. He is explaining in the beginner point of view
@tanaysamanta4730
@tanaysamanta4730 2 жыл бұрын
I ain't able to figure out the example of operator overloading :(
@moinafsana5945
@moinafsana5945 4 жыл бұрын
Since last Monday I have started to watching your videos . Now I am in #60.. , ultimately your teaching skill is too good . I have some basic core java knowledge, that's why I can catch up quickly and without you I couldn't go in depth in python.. thank you very much for sharing those materials . Appreciate your hard work.
@ankitajain2883
@ankitajain2883 4 жыл бұрын
He is probably the best instructor to learn from! He teaches with so much clarity! Hats off!
@alicandonmez6748
@alicandonmez6748 4 жыл бұрын
You are a talented teacher! Happy that i've found you. Keep up the videos coming
@sairajdas6692
@sairajdas6692 5 жыл бұрын
Wow I never knew about these double underscore function. Glad to learn new things from your channel. Thank you sir.
@madansirish9356
@madansirish9356 4 жыл бұрын
Excellent explanation I ever heard. You are amazing. Your teaching skills are at a peak. Impressed.
@surajjena1437
@surajjena1437 4 жыл бұрын
Thanks superhuman for this great explanation, right now I can feel what is happening behind the scene
@sm07
@sm07 Жыл бұрын
I was here to learn what operator overloading is. At the time of the end of the video, I learned about the structure and how the things behind the scene gonna work. Take a Bow Navin Sir.
@mbumbamwalila4224
@mbumbamwalila4224 3 жыл бұрын
Thanks, sir! from now on, you opened my eyes on what python can do. All confusions are gone from my head. I really understand python now.
@Mushsayer
@Mushsayer 3 жыл бұрын
Clearly explained the concept of method overloading in Python. Thank you!
@vasudevareddy5378
@vasudevareddy5378 5 жыл бұрын
One of the Good lecture, Students need teachers like you
@mukulvishwas6691
@mukulvishwas6691 4 жыл бұрын
The way you explained the connection and flow behind the code was exceptionally well, your video increasing my knowledge of python exponentially.
@divyanshusingh6105
@divyanshusingh6105 3 жыл бұрын
Really I never understand this topic... But nowww i really know the meaning of operator overloading! Hats off to you sir🙌
@sarthakyadav9950
@sarthakyadav9950 2 жыл бұрын
Thanks for providing quality content for free it's better than most of the paid courses out there . You are just amazing.(:
@engineeringwithprogramming
@engineeringwithprogramming 3 жыл бұрын
Finally in this tutorial somethings I couldn't understand started making sense, thanks to this man!
@shrikarp7233
@shrikarp7233 3 жыл бұрын
Sir u literally thrown away my difficulty of understanding magical methods 🔥
@GamingSunDBZ
@GamingSunDBZ 4 жыл бұрын
Excellent video...finally understood the concept
@khalidelgazzar
@khalidelgazzar 4 жыл бұрын
This is one hell of a great video! Thank you
@Praveenkumar-wv8qy
@Praveenkumar-wv8qy 4 жыл бұрын
great sir again the imformation which will add some values in my life😍
@rabilrbl
@rabilrbl 3 жыл бұрын
Great explaination! Its crystal clear for me now.
@adarsharora6097
@adarsharora6097 8 ай бұрын
This video was very informative. Feels good to understand how magic methods works. Thanks Navin Sir!
@TM-ej9mr
@TM-ej9mr 3 жыл бұрын
Best Tutorial series in youtube ..........Love Sir
@bhuvanaguna7782
@bhuvanaguna7782 4 жыл бұрын
thank you for your excellent class...I felt very very happy..thank you sir
@milimishra6447
@milimishra6447 5 жыл бұрын
Ur python videos are awsmm.. watched all ur videos on python . waiting for next videos on python..pls keep making videos on python..thankuu sir
@EylulTurksever
@EylulTurksever 4 жыл бұрын
thank you for your amazing lessons sir. def __str__(self): return " ".join(map(str, [self.mark1, self.mark2]))
@bandhanmondal4685
@bandhanmondal4685 2 жыл бұрын
this is the best channel on youtube to learn coding
@arihantjain4344
@arihantjain4344 3 жыл бұрын
Are concepts really so easy,or it's his teaching that's making them??
@TheKapilsharma143
@TheKapilsharma143 2 жыл бұрын
After waching video in sequence this is the firts video i enjoy in diff way. ;)
@namansingh8081
@namansingh8081 4 жыл бұрын
Thnx very much I'm having exam tomorrow very nicely explained
@motog9464
@motog9464 5 жыл бұрын
Awesome sir... Also being an educator, I can imagine how much effort you are putting in these videos.👍
@harshavardhandsh5190
@harshavardhandsh5190 5 жыл бұрын
How cruel are these language developer, can they not make this little easy....
@amongdoomers9464
@amongdoomers9464 4 жыл бұрын
@@harshavardhandsh5190 Python is easy thou
@RavikanthTalakoti
@RavikanthTalakoti 3 жыл бұрын
I can also see the effort you put in these videos, Navin sir. And today is my birthday Navin sir!
@fathimathsameera9593
@fathimathsameera9593 2 жыл бұрын
Your classes are amazing...
@moinafsana5945
@moinafsana5945 4 жыл бұрын
Excellent Sir .. now I feel like a coder 😁
@cokcury
@cokcury 4 жыл бұрын
hat's off guruji, im glad that people are aware about the marks comparison way, i aint a fan that way either. but as you said on youtube it might have reached a mass crowd...
@ravitejathumnoori1450
@ravitejathumnoori1450 5 жыл бұрын
sir, can you make videos on REST API using python
@maheshvangala8472
@maheshvangala8472 3 жыл бұрын
Just Enjoyed It Thanks
@kartickchandramanna267
@kartickchandramanna267 Жыл бұрын
Awesome lecture. Thank you sir 🙏
@s.baskaravishnu22
@s.baskaravishnu22 5 жыл бұрын
your explanation is excellent
@raihankhanphotography6041
@raihankhanphotography6041 3 жыл бұрын
You're an awesome teacher!
@vickyjha6839
@vickyjha6839 4 жыл бұрын
Thanks a lot sir you cleared my doubts
@abdmjd
@abdmjd 2 жыл бұрын
This is good and just. Thank you.
@BrighterWay
@BrighterWay 4 жыл бұрын
As useal greater explanation sir💯💯
@deepenpatel5403
@deepenpatel5403 4 жыл бұрын
Can we overload the '__add__' method multiple times inside the same class? (Each method having its own different code)
@jdranpariya3601
@jdranpariya3601 5 жыл бұрын
Hi sir will you teach advance python like networking with python etc...
@surajkottayi2451
@surajkottayi2451 3 жыл бұрын
Just amazing 😊👍
@AyushSharma-be4kh
@AyushSharma-be4kh 4 жыл бұрын
Best Way one can teach ! Appreciative content.
@bhaveshmevada8424
@bhaveshmevada8424 5 жыл бұрын
Sir what next after this basic ?? Blockchain or advance python??
@ShaheenPatan
@ShaheenPatan 2 ай бұрын
00:03 Operator overloading allows usage of operators with user-defined types like strings and classes. 02:02 Python uses methods to carry out operations like addition. 03:48 Operator overloading allows defining how operators work with user-defined classes. 05:36 Operator overloading allows us to define custom behavior for operators 07:28 Python allows operator overloading for custom classes 09:08 Operator overloading allows custom comparison of objects. 10:59 Operator overloading and polymorphism in Python 12:43 Operator overloading in Python allows us to customize the behavior of operators.
@tkdevlop
@tkdevlop 5 жыл бұрын
amazing concepts
@subhamthemusicalguy8851
@subhamthemusicalguy8851 2 жыл бұрын
Excellent explanation
@abhiseksingh6550
@abhiseksingh6550 5 жыл бұрын
Good learning point
@Skaxarrat
@Skaxarrat 5 жыл бұрын
When you print an object (and everything in Python is an object), it calls automatically the __str__ method, so we don't need to call it. 'print(s1)' would be enough to do the trick.
@bhetu_sagar
@bhetu_sagar 3 жыл бұрын
I love you bro!!! superb..
@gouravchouhan1790
@gouravchouhan1790 3 жыл бұрын
That's who things should be taught, loved the way you created a some background
@papreedhar8278
@papreedhar8278 5 жыл бұрын
Grt teaching sir..
@eliehaddad84
@eliehaddad84 Жыл бұрын
This man is a genius 🙌
@Laith.Alkhazragy
@Laith.Alkhazragy 3 жыл бұрын
this is not so easy to understand, you did it also very quickly.. anyway thank u very much ..
@keshavashukla
@keshavashukla 3 жыл бұрын
Amazing video , And an amazing series. can we say that defining __str__ is an example of operator overriding ? also is there anything like operator overriding ?
@mariaxia2687
@mariaxia2687 4 жыл бұрын
Thank you for uploading these awesome lectures, Sir. There's a typo in this video though. "Syntactic Sugar" instead of "Synthetic Sugar".
@habibahmad9415
@habibahmad9415 3 жыл бұрын
Sir you are passing double values through s1 & s2 but it added only first values of both s1 & s2 ...my question is where second values has gone
@theanirudhroy
@theanirudhroy 2 жыл бұрын
I was looking in the comment section to see if anyone has asked this particular question, I have no idea what other people understood !
@alexvajith6337
@alexvajith6337 2 жыл бұрын
print ("this man is legend! Thank You So Much sir💗") - from Student class all over the world
@leyanthreddy1436
@leyanthreddy1436 4 жыл бұрын
Really u r awesome sir
@indreeshpandey343
@indreeshpandey343 3 жыл бұрын
sir please bring up a series of python for intermediate where we can understand advance concepts of python.
@santhosha1312
@santhosha1312 Жыл бұрын
Sir Your videos are like preparing tastiest Briyani and giving it as service for free 😃🥰🥰
@rushilmehta4415
@rushilmehta4415 3 жыл бұрын
How can we know which method is called in the behind if we use a specific operator?
@raghavagarwal3163
@raghavagarwal3163 4 жыл бұрын
Can we directly import sum of marks i.e. m1 and m2 from add method and check them in greater than method instead of again adding marks?
@mariamkhanam4037
@mariamkhanam4037 2 жыл бұрын
Bro, I was checking PyQt5 Module. I saw "@typing.overload" in most of the functions. I don't understand what are that for? Can you explain?
@ROHIT-gv7xk
@ROHIT-gv7xk 5 жыл бұрын
nice video sir
@bhagyalakshmibadiginchala38
@bhagyalakshmibadiginchala38 4 жыл бұрын
I have a doubt about these statements will you please explain.. X+y is translated into x.__add__(y) If x has not implemented __add__ and x,y are of different types then y.__radd__(x) is called. There are equivalent "r" methods for all magic methods just mentioned.
@kenshinnanashi9469
@kenshinnanashi9469 5 жыл бұрын
These tutorials are great, but it would be a lot better to watch if the code in the background was a bigger font and/or more zoomed on, couse althought the content is awesome, you can hardly read the code it self.cheers
@saiavinash1200
@saiavinash1200 3 жыл бұрын
Sir, when str method is overloaded, why print(s1) did not work to give tuple atleast....why did it ask for string ,we can use print statement to print tuple also right!!!!!!!!
@atharvsarathe540
@atharvsarathe540 2 жыл бұрын
also please explain the difference between data type and class. is int, list , str a class or are they data type?
@chinmayraut6058
@chinmayraut6058 3 жыл бұрын
what if we get many teacher like him . . . . . . . . . In no time INDIA will be a super developed country
@mysketchbook9630
@mysketchbook9630 5 жыл бұрын
Thanks Naveen, every time I go through your video, I thank you and your team.
@Ihsan_almohsin
@Ihsan_almohsin 2 жыл бұрын
you are just awesome
@nikhil6842
@nikhil6842 2 жыл бұрын
I was frustrated since there’s no custom sort method for heapq. Hell i was Huma switch to c++ , but you explained it greatly
@mohdsaif8423
@mohdsaif8423 Жыл бұрын
Hi Naveen, what are the programs used in Product development Programs Kindly make video
@gorrepatimadhu6025
@gorrepatimadhu6025 3 жыл бұрын
Sir,Can u clarify how to get list of inbuilt functions by clicking ctrl?I am not able to get?
@skrishnan9625
@skrishnan9625 4 жыл бұрын
*excellent teaching sir. i think I would get good marks in my 11th standard
@pymondo1147
@pymondo1147 5 жыл бұрын
So amazing sir.. Thank you for the awesome tutorial.
@kulamritbamrah4880
@kulamritbamrah4880 4 жыл бұрын
Actually, the __div__(self,other) magic method for operator (/) is only for Python 2.x. For Python 3.x -- as I have found -- the (/) operator call the __truediv__(self,other) magic method.
@abhiseksingh6550
@abhiseksingh6550 5 жыл бұрын
Thank you sir
@rachanasawant1204
@rachanasawant1204 3 жыл бұрын
Cntrl + click isn't working in spyder for in-build class manual. please suggest!
@pawnage3
@pawnage3 2 жыл бұрын
Thank you so much!
@srujanapavanpatwari8502
@srujanapavanpatwari8502 4 жыл бұрын
There is no div magic method, please can you tell me for division how it works
@moky4mido
@moky4mido 5 жыл бұрын
thank you a lot ❤
@Sathishkumar-oj3sw
@Sathishkumar-oj3sw 4 жыл бұрын
how is it possible to call methods by the class, shouldnt there be an object first and then call the method?? someone please clarify. thanks in advance
@ronakprajapati2103
@ronakprajapati2103 5 жыл бұрын
thank you sir...
@sukruthh1
@sukruthh1 4 жыл бұрын
Hi Navin, I was trying to overload the "__truediv__" operator and could see that its having an issue. Below is my code. Please do let me know, if i am doing anything wrong. BTW, i am using the Python 3 version :- class Stduent: def __init__(self,m1,m2): self.m1=m1 self.m2=m2 def __truediv__(self,other): m1=self.m1/other.m1 m2=self.m2/other.m2 s3 = Student(m1,m2) return s3 S1=Student(20,40) S2=Student(10,20) s3=S1/S2 print(s3.m1) TypeError: unsupported operand type(s) for /: 'Student' and 'Student'
@deepanshubabbar9324
@deepanshubabbar9324 5 жыл бұрын
i have a question. Can you please tell me why you have written s3=Student(m1,m2) inside the __add__(self,other) method. I am not able to understand this. Please tell this.
@SpontaniousGuy
@SpontaniousGuy 5 жыл бұрын
By adding s3 = Student(m1,m2) under the __add__ function, this will automatically 'create' another 'student' with the resultant marks.
@justweird1015
@justweird1015 5 жыл бұрын
sir is this all python videos enough for toget basic knowledge in python..
@alpabhanushali3512
@alpabhanushali3512 4 жыл бұрын
What if we want to add 3 values by method overloading...? 🤔 Like... s4=s1+s2+s3
@ronniesam9941
@ronniesam9941 3 жыл бұрын
Sir can you explain how the if condition (out side __gt__ method) is connected with __gt__ method ASAP
@054_ritesh3
@054_ritesh3 3 жыл бұрын
Print(S1.AMAZING,S1.AWSOME)
@unnatiagrawal8936
@unnatiagrawal8936 4 жыл бұрын
inside int class in add function self is argument which means add method is instance method.why we are able to call "int.add " it should be object.add()
@saviofernandes5263
@saviofernandes5263 3 жыл бұрын
At 1:24 it's supposed to be "Syntactic Sugar"
@kaushalkishor4404
@kaushalkishor4404 2 жыл бұрын
No doubt, explanation is quite perspicuous. I am just curious how print(a+b+c) performed behind the scene because __add__ can add only two number Any Explanation/suggestion will be highly appreciated
@ihateracistandblackpeople4272
@ihateracistandblackpeople4272 2 жыл бұрын
it's too late but if you're still curious then variable length argument concept would be used in that case,you would accept the b,c in a list in the formal args and then perform the addition by using required mean like iteration etc
@MohitKumar-kh6mv
@MohitKumar-kh6mv 3 жыл бұрын
Awesome Awesome Awesome
#63 Python Tutorial for Beginners | Exception Handling
15:59
Telusko
Рет қаралды 492 М.
🍟Best French Fries Homemade #cooking #shorts
00:42
BANKII
Рет қаралды 32 МЛН
Chips evolution !! 😔😔
00:23
Tibo InShape
Рет қаралды 42 МЛН
WHY IS A CAR MORE EXPENSIVE THAN A GIRL?
00:37
Levsob
Рет қаралды 12 МЛН
Мастер и Маргарита: Мессир, мне больше нравится Рим
33:50
Екатерина Шульман
Рет қаралды 153 М.
Functions in Python are easy 📞
10:38
Bro Code
Рет қаралды 379 М.
#58 Python Tutorial for Beginners | Duck Typing
6:17
Telusko
Рет қаралды 330 М.
Типы Школьников на Каникулах !
27:40
Морковь PRO
Рет қаралды 732 М.
Python OOP Tutorial 5: Special (Magic/Dunder) Methods
13:50
Corey Schafer
Рет қаралды 839 М.
Abstract Class and Abstract Method in Python
12:29
Telusko
Рет қаралды 344 М.
Теперь это его телефон
0:21
Хорошие Новости
Рет қаралды 1,7 МЛН
Apple, как вас уделал Тюменский бренд CaseGuru? Конец удивил #caseguru #кейсгуру #наушники
0:54
CaseGuru / Наушники / Пылесосы / Смарт-часы /
Рет қаралды 4,5 МЛН