Inheritance in Java Tutorial #86

Sdílet
Vložit
  • čas přidán 27. 08. 2024

Komentáře • 514

  • @alexlorenlee
    @alexlorenlee  Před 10 měsíci +8

    If you’re new to programming but want a career in tech, I HIGHLY RECOMMEND applying to one of Springboard’s online coding bootcamps (use code ALEXLEE for $1,000 off): bit.ly/3HX970h

  • @SnobbyLion
    @SnobbyLion Před 4 lety +936

    I love how you start every video by calming us stressed-out students down. Really makes me feel better :)

  • @keving6758
    @keving6758 Před 3 lety +42

    "I know how to make a for loop... but how is that gonna help me make a mouse?" the most realest shit ever said

  • @ankonbiswas6054
    @ankonbiswas6054 Před rokem +49

    Went to a 1.5 hours university lecture to understand this. Professor ended up confusing everyone of us, we started stressing out. Came down on CZcams and found out this legendary channel. A 10 mins video to the point and precise and this topic is actually so simple! University is a scam fs

    • @joek5930
      @joek5930 Před rokem

      I am taking an Advanced Object-Oriented Programming course for college right now, and Alex's videos are the only reason I understand any of the course material. The book that we are assigned seems to go out of it's way to be as complex as possible and to use the most confusing terminology. Also, I am an online student so I do not get the luxury of a professor in the room with me as I am trying to learn. Moreover, the course is only 8 wks long, how in the world do people learn any concept with only 7 days worth of focus and one labs worth of use? I have 20 years of welding experience and I know for a fact that we do not expect our new-out-of-school welders do understand antything. It takes at least 6 months to a years worth of welding to fully comprehend everything that goes into a simple t-joint weld. Sure you can lay the bead but do you understnad the thermodynamics, do you understand how a voltage change is going to affect the weld penetration, do you know what will happen if you use those settings on a different material, do you understand how a bevel will affect the weld in this scenario......Yet Universities expect people to grasp these complex java concepts in a week. LOL

    • @okdarius
      @okdarius Před 8 měsíci

      Yes because watching youtube videos too awards you with a degree!

  • @ndought
    @ndought Před 4 lety +162

    Hey alex...i was in the military and did HVACR work for the last 3 years but was looking for a career change to something more rewarding. i just started my coding bootcamp jan 13th, its a four month program. i have been watching your videos for extra study materials in the evening and they have been very helpful so far. i have also shared them with some classmates as well. keep up the good work!

    • @dovydasbalciunas5002
      @dovydasbalciunas5002 Před rokem

      Are you a programmer yet?

    • @ndought
      @ndought Před rokem +7

      @@dovydasbalciunas5002 actually I went into corporate sales for a medical device company, the $ is too good to pass up! But what I learned regarding dev helped me every step of the way

    • @jdjjsnsnsjdjdjsjsnsj4457
      @jdjjsnsnsjdjdjsjsnsj4457 Před rokem +5

      @@ndought amazing to hear man. Congratulations and God bless

    • @ioliver6788
      @ioliver6788 Před 10 měsíci +2

      congrats man@@ndought

    • @ndought
      @ndought Před 10 měsíci

      Ty!

  • @yixingsikram982
    @yixingsikram982 Před 5 lety +158

    WHY HAVEN'T I DISCOVERED YOUR CHANNEL EARLIER !! thanks alot this was so helpful !!

    • @somalifreelancer6196
      @somalifreelancer6196 Před 4 lety +2

      you are delicous girl

    • @mngf749
      @mngf749 Před 4 lety +2

      I have discovered him the day ı starded programing :d

    • @mngf749
      @mngf749 Před 4 lety +5

      @@somalifreelancer6196 ıf you will be weird on youtube, at least try to hide the name of your country. you are the shame of somali

    • @_veselin_5048
      @_veselin_5048 Před 4 lety

      Actualy hi's entire Chanel is super helpful.

    • @otpreet
      @otpreet Před 4 lety

      Immanuel Kant that’s a good thing

  • @bradleyli1569
    @bradleyli1569 Před 3 lety +57

    This is literally the clearest explanation I've seen on the concept of inheritance. Have been struggling on this concept for almost a month.

  • @ktown5422
    @ktown5422 Před 5 lety +95

    Thanks man, you simplify things in a way that I can grasp

  • @latedeveloper7836
    @latedeveloper7836 Před 3 lety +55

    1:45 Initial example: create multiple gaming mice as objects in this project
    2:17 Set up with empty classes, no main (no inheritance)
    2:41 Starting with mouse object 1 (no inheritance)
    3:26 Mouse 2 object + special features (no inheritance)
    3:52 Mouse 3 object + special features (no inheritance)
    4:18 Overview of the 3 mouse objects and how inheritance can save on redundant code
    4:45 Solution to making gaming mice at scale: making a generic mouse class with inherited code
    6:02 How to use inheritance: generic mouse with its properties applied to any number of other mouse objects
    6:11 How to use inheritance with other classes (extends)
    6:35 Creating a main method to test
    6:40 Creating first mouse and how to view all the generic methods in scope for another mouse class (using the main method)
    7:06 How inheritance can access methods not visible in the individual mouse classes
    8:05 How to also access specific properties for an individual mouse class
    8:25 What inheritance does for programs plus real-world examples e.g. cars
    9:19 Summary of what inheritance is (using methods and properties from a generic class and making different versions of them)

  • @ethanlyons5141
    @ethanlyons5141 Před 3 lety +48

    Spent one year in a coding bootcamp. Everything went over my head. 3 days with your videos and I feel like I could actually start looking for a coding job soon.

  • @AnaitiArauz
    @AnaitiArauz Před 3 lety +72

    when he said "you're gonna be ok because I'm gonna walk you through" my heart felt that T_T #CoronaOnlineFinalzSuckkk

  • @kristorastas7765
    @kristorastas7765 Před 4 lety +4

    i've got a 4-hour java exam in an hour, watching your playlist in 2x speed, you da real mvp

  • @bscorvin
    @bscorvin Před 3 lety +8

    It is strangely comforting to be told by the java tutorial I’m watching that I’ll be ok.

  • @ellie-8777
    @ellie-8777 Před 4 lety +52

    This was super helpful, especially during the quarantine that's going on right now. Definitely subscribing to your channel.

  • @juanpalmtree
    @juanpalmtree Před 3 lety +3

    I cannot stress this enough, but your videos have helped me to understand things so much better! As noobish as this may sound, I'm taking a Coursera course and all the instructors/professors on there make ZERO sense to my pea brain. But then I come over here to watch your videos and I understand everything as if I was in middle school all over again. It just clicks so well! Thanks for your guides! (:

    • @juanpalmtree
      @juanpalmtree Před 3 lety +1

      Also, why is it that you have found a way to use words that don't sound like gibberish? Why does every word used in programming seem to be another language besides English? You speak and I ACTUALLY understand you!

    • @alexlorenlee
      @alexlorenlee  Před 3 lety +3

      to me, I think it's because people programmed for so long they came up with specific words for specific coding reasons. But if you haven't coded for a long time, how are you supposed to understand them? Exactly. I try to teach like I would teach a friend, and I don't care about sounding smart by using big words

  • @bubble418
    @bubble418 Před 3 lety +3

    best thing i’ve ever done is watch ur videos while i’m on break i feel like i’m still learning

  • @MrZeybel
    @MrZeybel Před 4 lety +4

    I have never thought that I would thank you to someone to feels me like I was an idiot. So, thank you Alex. You really helped a lot understanding its philosophy.

  • @RandomGuy01947
    @RandomGuy01947 Před 3 lety +3

    Your examples are very calm and not complicated. Truly helpful.

  • @tombean343
    @tombean343 Před 4 lety +17

    Nice one dude, you're so helpful, I started learning Java 3 days ago outside of school and am almost as confident as I was in python which I have been learning for 2 years!!!!!

    • @richard6304
      @richard6304 Před 4 lety +1

      Tom Bean Wow.. you really didnt know anything about python.. :0 (joke ofc

    • @integral1191
      @integral1191 Před 3 lety

      @@richard6304 i definatly was thinking that

  • @drorzenerd2372
    @drorzenerd2372 Před 3 lety +7

    I'm in 10th grade, your videos not only boosted me 1 year above the rest of my class, but inspired me to work on my own projects which boosted me 2 years (and more) above my class.
    Every time I hear "you probably have a test coming up", I think to myself "I do have a test coming up, in around a year"
    I'm so happy I found you when I started learning by myself.

  • @omarahmed7608
    @omarahmed7608 Před 4 lety +6

    Alex, please keep going. I love your vids man! They help me a lot with my classes.

  • @nurinroslan4048
    @nurinroslan4048 Před rokem

    Woke up after nap for 1hour, strictly play back your video and try create my own, boom! just like that i can understand!!! Very helpful!!

  • @featherfly1197
    @featherfly1197 Před rokem +1

    Thank you so much, I just started my second semester of computer science but missed the first lectures about OOP because I got covid. I tried to do our first assignment by myself with only the help of the lecture slides but felt so lost. This video really helped me!

  • @iyinfat3091
    @iyinfat3091 Před rokem

    You didn't complicate anything, smooth and easy to understand... Appreciate

  • @marialois2555
    @marialois2555 Před 3 lety

    Reading a boring website with absolutely no design or creativity < Watching a fun youtube tutorial that actually grabs my attention.
    Thank you!

  • @jasonchip420
    @jasonchip420 Před rokem

    I've spent 2 months trying to get this into my head, but idk if its the idea of the "mouse business" or your what but I finally got Inheritance into my brain. Thank you Alex I really appreciate it 😁

  • @zacharyvice4687
    @zacharyvice4687 Před rokem

    Final review for my test in an hour and a half, couldn't be more thankful I found your channel

  • @rittenbrake1613
    @rittenbrake1613 Před 4 lety

    NO ONE explained this topic as clear as you do ! It's super easy to understand by using mouse features as an example , GOOD JOB !

  • @misch4450
    @misch4450 Před rokem

    I have been struggling to understand these concepts of OOP for years, but one look at your tutorials, and I finally understood. You have explained these principles a lot better than all of my professors combined! I just want you to know how grateful I am. Thank you! Thank you!

  • @kickass7938
    @kickass7938 Před 2 lety +1

    You’re the best alex… i have been watching your videos since i started my bachelors and your videos are extremely helpful… Thanks much appreciated:))))

  • @RhoChalmers
    @RhoChalmers Před 3 lety

    Much clearer than the explanations by my current Java professor. He combined several of your videos into a single explanation, but didn't clearly highlight each element such as OOP concept, Inheritance, and Constructors. He also gave us some VERY dense terminology/explanations. Thank you for making these videos. I have shared your channel in our IT/CS Discord.

  • @melissajohnson6649
    @melissajohnson6649 Před rokem

    OH MY, you are the best! I have been trying to find videos for my students to watch that are not dull. :)

  • @YesDiscovery
    @YesDiscovery Před 3 lety +3

    Thank you so much man, your videos are so simple and clear, it makes it so easy to understand a lot on concepts in Java, please keep posting your amazing videos.

  • @dimitarvelinov277
    @dimitarvelinov277 Před 2 lety

    Alex, you are an amazing teacher! A comment from some dude twice your age, who studied law and is brand new in your field.

  • @sunkumohith4650
    @sunkumohith4650 Před 3 lety

    You killed it, by starting with a proper example. There is no stress while watching it.

  • @entitysa
    @entitysa Před 5 lety +11

    You've literally helped me so much. Thank you!!! Keep the videos coming. Peace out :)

  • @jayshankar82
    @jayshankar82 Před 2 lety +1

    Examples of Mice and BMW was very useful. Thank you. One Suggestion, I have noticed, 4-5 Minute videos are easy to grasp.

  • @Wife4Lif3
    @Wife4Lif3 Před rokem

    I understand Java better when watching your videos. Thank you!

  • @patricryan7282
    @patricryan7282 Před 3 lety

    Beautiful , you are a natural teacher , very gifted ,well done .

  • @weendylry5598
    @weendylry5598 Před 3 lety +1

    Your voice is so soothing it literally melts away my stress

  • @arjanitbeqiri3145
    @arjanitbeqiri3145 Před 2 lety

    I’ve been going through Udemy Courses, private courses and stuff but Alex Lee’s courses were the ones that I really understood. Straight to the point, no trash talking, simply explanation.
    Thank you for those videos

  • @lliw5695
    @lliw5695 Před 2 lety

    You absolute weapon! You made programming much more fun than i have ever imagined. I hope you win the lottery Mr Lee.

  • @balajis9182
    @balajis9182 Před 4 lety +2

    Thanks bro , now I have cleared all my doubts the best CZcams Java channel in CZcams is Alex love u bro please make more with Java to develop peopel like me and more .... 🙋🙋🙋🙋🙋🙋

  • @eliasdil5492
    @eliasdil5492 Před 2 lety

    This mouse example was the best example for the inheritance, thank you!

  • @rohanshrestha2293
    @rohanshrestha2293 Před 20 dny

    Don't worry you didn't overcomplicate it! This was really helpful! Thank you!!

  • @daefaux5670
    @daefaux5670 Před 2 lety

    You didnt complicate anything, just made everything easy to understand! Bless you

  • @2003MAAP
    @2003MAAP Před rokem

    Alex, I have to study Java for college but it was overwhelming to not get used to the terminology, I came across your videos and explanations and to see that I am not the only one who understands things differently and has this material to understand in another way. I just love it thanks so much for the explanation helped me a million times.

  • @asht7788
    @asht7788 Před 4 lety

    You are the best man! The professors send me to a nested loop of confusion, but your short videos really help. Thanks.

  • @SiKside
    @SiKside Před rokem

    Thank you, this example really helped. I am struggling with my second college programming class and you are a lifesaver! I'd much rather learn the concepts by watching your videos than have to cheat on everything with chegg.

  • @dylanpene1638
    @dylanpene1638 Před 2 měsíci

    The mouse example was Perfect

  • @milolife5055
    @milolife5055 Před 5 lety +3

    hi bro i bro i really like the way you explain things , i did not know any thing about java but when i start watching your videos i know a lot thank you so much Alex

  • @damianztone
    @damianztone Před 2 lety

    This explanation was half time and better than my actual CS class

  • @cheemborg1301
    @cheemborg1301 Před 4 lety +3

    You covered more in 10 minutes than my proffessor in nearly 2 hours

  • @matushricik8345
    @matushricik8345 Před 3 lety

    I rarely comment on CZcams or any website for that matter, but this tutorial was ridiculously cool. Great straight to the point video. 10/10 easily

  • @CodingKida
    @CodingKida Před 4 lety

    In my life, I think this is first time I understand java concept... Keep posting...

  • @sydneyhanson9637
    @sydneyhanson9637 Před rokem

    Thank you for the help. You explain this much more competently than my professor.

  • @hamidali2528
    @hamidali2528 Před 4 lety

    The Mouse example was excellent i grasped it easily , keep up the good work .

  • @jonassvirplis1234
    @jonassvirplis1234 Před 2 lety

    dude this is by far the best thing ive seen on java, easy to understand, well made. all round amazing video, thanks a lot!!

  • @thaisb.6530
    @thaisb.6530 Před 4 lety +1

    Alex, your videos are always helpful. I'm just starting with programming which I always thought was crazy hard but you make it possible to learn (it doesn't scare me anymore). Thanks for your videos, thanks for your time!

  • @chitaluchabu
    @chitaluchabu Před rokem +1

    Wow Thank you Alex. You make the most complicated concepts so easy.

  • @verisad3472
    @verisad3472 Před 2 lety

    ok I know I came here for the tutorial but I really needed to hear the "you'll be okay" at the start
    I have a quiz tmr and I've been really anxious all day but this made me feel so much better

  • @keshinrotobi9725
    @keshinrotobi9725 Před 3 lety

    Thank you so much Alex, I always search for your videos first when i dont understand a concept in Java

  • @hasancete43
    @hasancete43 Před 4 lety +3

    You are the best so far. Thanks alot!

  • @ramvenkat9191
    @ramvenkat9191 Před 2 lety

    the simplest and most understandable explanation;

  • @azizt6773
    @azizt6773 Před 10 měsíci

    you've done it more than simple thanks Alex👍

  • @MFNJairah
    @MFNJairah Před 3 lety

    At first, I was so disgusted at him coz he everyday shows up on my recommendation. But now, I love this guy coz he helps me a lot! Algorithm of CZcams knows what you really NEED. Thank you, man!

  • @kebbadumbuya5920
    @kebbadumbuya5920 Před 3 lety

    honestly, I just like the way you teach

  • @og_gaming2323
    @og_gaming2323 Před 3 lety +2

    I'm no college student. But I'm a 14-year-old who's bored in quarantine and your videos made me understand java that I'm studying well to make sure I go to my dream university
    Thank you

    • @to_her_dismay4405
      @to_her_dismay4405 Před 3 lety +1

      if you plan on pursuing coding in college. I definitely recommend learning java beforehand. It will make your college experience so much easier. trust me! Im currently a sophomore taking computer information system classes, which are basically learning how to code. I wish I would've learned more before college started.
      best of luck:)

    • @og_gaming2323
      @og_gaming2323 Před 3 lety

      @@to_her_dismay4405 Thanks

    • @Believer1995ofGod
      @Believer1995ofGod Před 3 lety +1

      @@to_her_dismay4405 yea it will help but its best not to get carried away, if you don't do OOP concepts the right way professor will take off points.

  • @SuperMrHolmes
    @SuperMrHolmes Před 4 lety

    Concise and easy to understand. Well done

  • @swift577
    @swift577 Před 3 lety

    Your videos are the best. Thank you, Alex Lee.

  • @skeptic3045
    @skeptic3045 Před 3 lety

    This is one of the best examples I have ever seen. Love the motivation of rationalization to introduce inheritance...

  • @AyushKumar-qd9oj
    @AyushKumar-qd9oj Před 4 lety

    This is the most useful video that is have seen this whole year. Keep it up man!

  • @harunsammmy
    @harunsammmy Před 3 lety

    I paid bunch of money of studying Java for no reason BUT i LEARNED , I RECOMEND YOU TO EVERYONE THAT COULD LEARN better way. Alex could you please make some videos about Selenium and Maven as well. I would really like to re learn that from you because your explaining is beyond other people Ive ever seen , at least with a perfect accent lol. GoodJob Alex

  • @adamheck3013
    @adamheck3013 Před 2 lety

    amazing example. im on my third attempt of learning java, and this video alone was better at introducing inheritance than any of my 3 profs ive had

  • @shrinking_brain816
    @shrinking_brain816 Před 2 lety

    I stumbled here because I have an activity and I didn't get some of my professor's discussion. Thanks a lot.

  • @yogeshg1868
    @yogeshg1868 Před 4 lety +1

    Your tutorials make things so much easier to grasp. Keep it up!

  • @mun6138
    @mun6138 Před 3 lety

    Thank you so much! instead of watching a 1 hour long lecture I understood in 10 mins

  • @mrboyban
    @mrboyban Před 3 lety

    CZcams needs seriously consider creating an ultimate virtual uni. There are far too many people on this platform that can contribute. The teaching I got from a top uni was crap, I was never taught much, just self-studying like a donkey when paying so much money.

  • @destrogod5984
    @destrogod5984 Před 5 lety +1

    You're the best. Will you start a series with more advanced topics? Like Spring framework?

  • @SephirothTheLegend
    @SephirothTheLegend Před 4 lety

    You sir are my savior.

  • @Khater-khan
    @Khater-khan Před rokem

    you explained so well, couldnt catch in the school as you explained

  • @NerdistRay
    @NerdistRay Před 3 lety

    Good way of explaining. I can say you put a lot of thought on this to make it seem very simple and easy to understand. At the end of the video, you were doubting yourself thinking you may have over complicated the video, that's definitely not the case. Thanks for the video.

  • @astonmargolis4391
    @astonmargolis4391 Před rokem

    ty king fav tutorial channel rn

  • @abdeselamselami4532
    @abdeselamselami4532 Před 4 lety

    Thanks a lot Alex, for everyone the short-cut of System.out.println() is type sysout + hit buttons ctrl+space.

  • @user-mv3wb3ne8p
    @user-mv3wb3ne8p Před 4 lety +1

    Thank you for sharing! 好人一生平安!

  • @FusRohDahlila
    @FusRohDahlila Před 8 měsíci

    So simple but so helpful, thank you!!!

  • @maureen6915
    @maureen6915 Před 3 lety

    You are very good at explaining, congratz from Sweden :)

  • @avinashs2194
    @avinashs2194 Před rokem

    thanks man your videos on abstraction encapsulation and inheritance and polymorphism helped me a lot!! thank you bro

  • @veronicakoskei8605
    @veronicakoskei8605 Před 2 lety

    I have really understand inheritance through your video
    I really appreciate

  • @nipplesniper
    @nipplesniper Před 3 lety +4

    "But how do we make that? well I know how to make a for loop" that laughed my face off

  • @gimaal1184
    @gimaal1184 Před 2 lety

    you're saving my life! thanks alex!

  • @chrizzly342
    @chrizzly342 Před rokem

    Very good one, Alex.
    And explained easily as ever! On my first two semesters, our prof made sure, that nobody understands even the easy parts of OOP :)

  • @lynnvillacorta6351
    @lynnvillacorta6351 Před 4 lety +1

    Your tutorials helped me a lot during this quarantine. Thank you so much! Its funny that i can easily understand your ways of teaching and idk why maybe because you interact well and construct those things effectively compared to my college instructors lol just keep doing it sir ur awesome

  • @SpooxyCowboy1911
    @SpooxyCowboy1911 Před 2 lety

    Someone get this man a medal

  • @GabrielConstantinides

    nice video to explain inheritance of methods from a superclass, what I would've liked to see is some talk about inheritance of instance variables, and the nuances when these variables are public or private in the superclass

  • @bruceunabia7980
    @bruceunabia7980 Před 3 lety

    YOUR VIDEOS ARE REALLY HELPFUL! IM REALLY GETTING THE HANG OF THIS OBJECT ORIENTED THANKS!

  • @adamameen5
    @adamameen5 Před 2 lety

    Woww. Just beautifully explained. I have now understood how to implement inheritance in Java.

  • @mrsbillypenaflor
    @mrsbillypenaflor Před 3 lety

    You're a fantastic teacher! Making it easy for the audience to understand when you share the knowledge is what's brilliant about your tutorials! I should have seen your channel and Java videos a lot earlier! Thanks so much, Alex :)

  • @rickaz1234
    @rickaz1234 Před 3 lety

    Who the hell did dislike this man! They should get a life!
    Awesome dude! Keep it up!

  • @marius310
    @marius310 Před rokem

    Love you man you stressed me out as a student