Inheritance in Java
Vložit
- čas přidán 27. 08. 2024
- In this video we will see how inheritance works in java and how to use extends keyword in java to create subclasses from super classes.
Notes will be made available at the end of the chapter.
►This playlist is a part of my Complete Java Course playlist: • Java Tutorials For Beg...
►Source Code + Notes - codewithharry....
►Ultimate Java CheatSheet: codewithharry....
►Checkout my English channel here: / programmingwithharry
►Click here to subscribe - / @codewithharry
Best Hindi Videos For Learning Programming:
►Learn Python In One Video - • Python Tutorial In Hin...
►Python Complete Course In Hindi - • Python Tutorials For A...
►C Language Complete Course In Hindi -
• C Language Tutorials I...
►JavaScript Complete Course In Hindi -
• JavaScript Tutorials I...
►Learn JavaScript in One Video - • JavaScript Tutorial
►Learn PHP In One Video - • Learn Php In One Video...
►Django Complete Course In Hindi -
• Python Django Tutorial...
►Machine Learning Using Python - • Machine Learning Tutor...
►Creating & Hosting A Website (Tech Blog) Using Python - • [Hindi] Web Developmen...
►Advanced Python Tutorials - • Intermediate/Advanced ...
►Object Oriented Programming In Python - • Object Oriented Progra...
►Python Data Science and Big Data Tutorials - • Python Data Science an...
Follow Me On Social Media
►Website (created using Flask) - www.codewithhar...
►Facebook - / codewithharry
►Instagram - / codewithharry
►Personal Facebook A/c - / geekyharis
Twitter - / haris_is_here
Kis kisne kitne videos dekh liye is course ke?
Waise course poora complete hoga! Dont worry 😊✌
Bhai Abhi tak saari videos dekhi hai course ki thanks for this course Harry bhai.
And please Harry bhai live at 1 million please. Many will able to clear their doubts related programming and everything.♥️🙏
All videos
Bhai mera insta pe dm padhlo plzz
Mera ek issue aa rha hai project me solve kardo maine mail bhi kiya hai
@@GOKU-Black242 abhi toh aadhe se jayda course bcha hua h bhai
After long time Harry bhaiya 🙏👍 thanku for this course keep it up bhaiya and reached 1 million subscriber
Bhai rukna mat, duniya bolti rahegi ! You are helping a lot of students....
Koun kahe ga bhaia
He helps Not only students but also employees😂
@@abhisheksoni4671 ..not only employees I think he help to coaching institute also.😂 teachers from coching might seeing his vedio 😂
@@Shweta-iy4zd o really
@@zeshantalat9399 it's true!
Worlds best Java course from the universe’s best coding teacher
Kuch jyada ho gya .....harry bhaiya itni bhi tarif nhi mangte....bas playlist ko access kr lo....bhut hai
@@Vivek-jc1bb lol
Bhai animal class wala practice set ka solutin de do plz...🙏🙏🙏
Beti tumaare shabd adal badal ho gaye hai
@@Vivek-jc1bb lol
Don't worry, you are doing great work already! You are helping a lot of students
chandu, tu yaha bhi
@@prateeksharma4703 ha
I am a student and i am financially weak and thank you so much for supporting like us students from these incredible java concepts videos that make us incremented in knowledge. Thank You!
What now ? After these videos what did u opt for ??
You are a great teacher watching your courses.... One by one...!You are so hardworking.😊Thank you so mch 🤘🏻😊
What now ? After these videos what did u opt for ??
13:30 Yes we can use 'getY' and 'setY' in derived class as the derived class contains both X as well as Y
This is the best playlist available to learn java and the most impressive fact is he enjoys making these videos. i have purchased java books but it seems as if my knowledge is complete without these videos. i fell in love with learning java, thanks Harry and wish you lots of success.
*incomplete*
What now ? After these videos what did u opt for ??
Harry sir ignore all those negative comments we are with you. If there are any delays no problem take breaks it is important for your mental and physical health. thank you so much for teaching us everything so clearly and in-depth we will always support you. I am an ECE student but I am learning coding from you I already completed the frontend of your course and made many websites now I am learning java from you thank you for teaching us.
Tip: Add disclaimer at start and in middle of video to stop those people who sell your content.
Yes, you are right!
u r right bro. but vdo edit bhi toh ho sakta hai !
I am following you for the last year and you are my first programming teacher harry Bhai. You are doing so great leave the negative views of peoples they use to do it.
i am very late to lear java according to your videos , but if you are reading this comment then i waana thank you harry sir ,you are lelping a lot of youths finantially by posting these amazing videos free on yt so great respect to you sir.
Sir first of all you are a great teacher...Though I am a student of circuit branch, never felt that this videos are more understandable for non-circuit branches. All of your courses are far more better than those paid courses. What ever I have learned about coding that's from you. My support will be always with you...Thank you so much sir
Bhaiya aapko humara full support hain! App kitna mehnat karke ye sab banate ho. If you want some rest you can obviously take it. you deserve it. You helped us a lot. Dil se shukria
Harry bhai please aap rukna you are helping lots of students jinhe college mai yeh topics smjh nii aate to ek aap hi last hope ho meri toh mai chahta hu mujhe saare topic sirf aapse seekhne ko mile sirf aur kisi ki videos se zyda aapki videos se seekhne milta h mujhe you are best teacher i think in the world jo inne simple way mai sb kuch sikha deta ho.
Love you alot❤️
13:30 yes we can use 'Y' because we can access the properties of parent class in child class as well as we can add additional feature in it...
Best coding channel on CZcams
Respect++++
13:20
Yes sir we can use sety and gety in derived because y is present in derived
Wonderful!! We are being taught the same thing in school right now and after watching this,the concept is clearer to me!!
"Kaya kar rahe hoo bhaii...." sir upki bolne ki style lajabab hyy.. love you sir..
class animal{
public void walking(){
System.out.println("they can walking!!");
}
public void eating(){
System.out.println("they can eating!!");
}
}
class dog extends animal{
public void barking(){
System.out.println("they can barking!!!");
}
}
class Main
{
public static void main(String[] args) {
animal a=new animal();
a.walking();
a.eating();
// a.barking(); this will error
System.out.println("--------------with respect to dog--------------");
dog d=new dog();
d.walking();
d.eating();
d.barking();
}
}
hey use-- they can walk or they are walking!
I've never seen a hardworking person!!!!!U have put so much efforts thank you !!goodvibesYou don't realise what you are doing. Educational videos like this can change someone's life. Amazing work
😁
Harry Bhai Ab 1 million subscribers karlo Jaldi
Intjar nahi hota bro ♥️♥️♥️♥️
mindblowing harry sir teaching way absolutely perfect
ive been watching this since start and I have learnt alot and m currently doing java in my colg and they dnt teach as well as u do, Please continue to post java videos, I am following ur playlist.
What now ? After these videos what did u opt for ??
Sir I appreciate your work and you are working a lot for us. I am very grateful.Happy durga puja sir
❤️
I was waiting for this video, after 4 days java video came. Thanks for this course.
Harrybhai...yaha 10 achhe hai to 5 bure hai lekin or ap per sham hote hote 1000 aise ate honge jo apko kya ku6 bolte honge fir bhi ap hum sabke liye itna karte ho or ap un kharab logo ko nazarandaaz karke hum sabki taraf dekh kr itni mehnat jo karte ho na uska hume bahot dil se Garv hai...Heads off to you bro...
13:23 yes we can use both x and y from the derived class
H.W:
class Animal{
public Animal(){
System.out.println("My class consists of all the animals as the name speaks for itself");
}
public void location(){
System.out.println("We live in the jungle");
}
}
class Dog extends Animal{
public Dog(){
System.out.println("Bow Bow");
}
public void speak(){
System.out.println("Hi, My name is lewis");
}
}
public class Inheritance_in_Java {
public static void main(String[] args) {
// Derived object=new Derived();
// object.setX(4);
// System.out.printf("Value of x: %d",object.getX());
//
// object.setY(10);
// System.out.printf("
Value of y: %d",object.getY());
Dog obje=new Dog();
obje.location();
}
}
Bro how you got sex and getx ,you did not made any method for it😅
Really appreciate your effort Harry bro❤️.even clg leture also not teach like this in the simple form.
U r becoming god for coders 😮🎉
Harry Bhai is really our physics wallah!! ❤️❤️❤️ Keep it up bhai❤️❤️❤️
We... We support you ❤️❤️ we love you Harry Bhai ❤️💙
Harry Bhaiyaaa is the best in explaining every little thing 🔥🔥❤️
hi di need help
Harry sir u r really great man.. I have done graduation in computer science but they never taught in such a good manner.. Really appreciated. Sir
hi bhaiya where r u working now?
Everytime you uploaded a video i snapped and saw it was ds and algo but finally its here
13:26 yes. we can use getY() in derived class.
18:33 Sir, I am very sad after hearing this, you put so much effort into this and others are making money from these free notes ( BTW I am not that guy). Keep this good work up well done. ( I will surely help you by liking and subscribing to your channel. Thank you so much🥰🥰💖💖)
Coaching , academic laganee ki jaroorat hi nahi padii sir.. . nice explanation....you are my ideal 🔥..I learn Java python very well form your playlist....shukriyaa...aaise hi videos upload kartee rehnaa....ye college Wale kuch itnaa samjatee nahi he 😂...faltuk me paise waste ho rahe he
Dont worry we are always with you sir . Sach mein aapke videos ke liye wait karna accha lagte hain . Is gap mein notes revised ho jata hain. Sir aap apna time maintain krke upload kariye videos. ❤❤
13:30 yes d object can use setY method
13:23 Yes sir we can.
Thanx bhaiya u are a form of god for us🥺🥺❤️❤️
You have no idea how lucky I feel because this playlist exists...
This is the world's best java course
sir tq for everything i'll always support u , me too bahot lucky hoon ki sab course complete hone ke baad dekh rahi hoon, yeh complete ho jaaye fir dsa bhi karna hain aur aapne matlab padhayi hain kya
I am from Bangladesh. I watched your classes and its helped me a lot.
MERN stack playlist next🙌
We all support you, we know that you need to also do your own stuff
Bhut hi bdiye kaam kr rhe ho aap salute h pure india k liye ❤❤
Hats of this man for amazing java playlist ✌✌❤
*Harry bhai Happy Durga Puja. I'm from west Bengal.*
🥰🥰
Happy Dussera Bhai❤
Happy Dussera Rohan bhai 🥰🥰❤❤❤
16:20
package quiz;
class Animal{
String CAT;
public String getCAT() {
return CAT;
}
public void setCAT(String CAT) {
this.CAT = CAT;
}
}
class Dog extends Animal{
String DOG;
public String getDOG() {
return DOG;
}
public void setDOG(String DOG) {
this.DOG = DOG;
}
}
public class Inheritance_java {
public static void main(String[] args) {
Animal a = new Animal();
Dog d = new Dog();
d.setCAT("Snow-bell");
System.out.println("Hello my name is " + d.getCAT() +"." + " I am a CAT ");
d.setDOG("Bruno");
System.out.println("Hello my name is " + d.getDOG() +"." + " I am a DOG ");
}
}
Bro at the last what is the use of
Dog d=new dod();
Dog ek child class ha tw jis trah hm class ko access krty hain uska object bna kr same usi trah Yahan pr iska object bnaya then values ko set krky get krwa kr print krwa diya@@Diosam7
you are fabulous bro..i m from non it background but made the course easy for me.long live harry bhai
Harry sir you are the best coding youtuber i have ever seen and you work a lot. Sir please make video on how to become a c developer
Video 45
Time 13:29
Yes Harry bhai we can use y by calling derived class.
Thank you for uploading all this it's really helping me to learning things
Kya kar rahe ho bhai counter = 6 times 😂
You're the best bro because of you many students are able to understand these concepts easily
@13:28 ha bhai. access kar sakte hai bcause derived class mein Y toh already available hai. you are the best teacher ever. Maine apne college se jitna nahi sikha utna aapse sikha hai. Thank you so much
You are the best.
Aap insaan nahi ek sanstha ho puri ki puri !
Sir You are great. really apke vajha se meri life mai bohot value addition hui hai. Thank you
your the best love your video love from pakistan
13.25 The code will Execute when we try to access the method of Derieved class by a derieved class object
i.e.
Derieved D = new Derieved() ;
d.setY(89);
d.setX(7);
System.out.println("Y == "+d.getY() + "(By creating the object of base class)");
System.out.println("X == "+d.getX() + "(Inheriting from the base Class)");
Hats off to you Sir. You helped lot of students. 🙌
Bhai ap continue kro dunia mai khrb log bhi h ap bhtt acha kaam kr rhe ho , hum jese beginners ke liye.. you are great 🙏🙏🙏
hi bhaiya
Thanks ....you would be the reason of my success
Harry bhai log jo bhi bole.. aap sahi kaam karre ho.. waqt lo.. jitna chaiye utna lo..
Aise faaltu logo ki baat pe dhyan dene ka hi nahi.. Cheers.
Sir mai aapke videos dekhti hu jo mere liye bhaut helpfull h .
So thank you soo much 😇😇😇😇
Bhai aap mere zindagi ko asaan ban diya
you are a saviour dont let others demotivate you..
Your efforts are Marvellous.
I leraned lots of things from your videos.
Thank You .
Thank you sir ap bahot achaa concept clear kar dete ho...❤️ Once again thanks
Harry bhai continue.... You are the best teacher. Please take your time and upload this type of videos
Yur are world best teacher for programming sir
Yes sir. Your are best CZcamsr for coding teacher
HARRY BHAI
I get placement in google because of you
Harry bhai I m your biggest fan I m from Pakistan And I Learned Python Web development machine learning DS and ALGO and many more thing from you you are my idol harry bhai
THANKS HARRY BHAI
in google???? congo brooooo
Bhiya Your Efforts is Unexpected last line was heart Touching I we trust and when I get something in my life then I want to do want to meet you. We love You Bhiya.
Dil se bahut bahut dhanyawad. Harry bhai. ❤️❤️ Bahut acha pda rhe ho ap.remarkable job.
I am learning C from your videos. Thank you very much :)
Harry sir aap best ho👍🙏🙂
You are so honest bro ❤❤❤❤
Sir tumhare sab course acha he. I love your chanel. mujhe akin he ap hamre liya bohut acha acha course le kar aaoge...Thank you Sir. Best off luck..
Harry Bhai we Love you❣❣
You are very good teacher
harry bhai very best teaching😀😀😀😀😀😀
Hatts of to Ur dedication .it takes a lot of motivation to encourage yourself to upload videos daily 🙏❤️🔥
jab koyi kuch accha karta hai to logung ko uskay achayi nazar nahi atta bas wo kab ghalti karay uskay intizar may rahta haii sir abb bohot accha padata haii hamaray dua apkay sath haii sir apnay ittna course free dia usay iski qadir nahi haii or bhi shikwa kar raha ahiii asay nahi karna chayi haii
13:23 yes we can access property Y and setY(int y) method from derived class object
Thank you so much for providing this meaningful and useful content.
Reallyyy reallyy greatful to youuuu....you are doing such a greattt job!!!.helpingg numerous students. Dailyyyy.....thank youuuuuu from the core of my heartttt!!!...
Love you bhai❤❤you are my real inspiration ❤❤❤
thanku sir mjha ya topic bilkul smjh ni a raha tha lakin ap ki video na sab easy kr dya 🥰🥰
You are best bro ,,,,,, apka course bohot hi helpful hota h ,,,,,,, nice video 👍👍👍👍
congratulations for 3 million
thank you 🎉🎉 Keep uploading !! forget about the toxic people
we are with you ..
👏
You are doing amazing and a very noble work Harry bhai, please take your time and ignore the rest. We will always support you.
Harry bhai, salamat raho hamesha. Hamain aapki bohot zaroorat he. Thanks a lot for these videos
13:24 yes we can as we have as Derived class contained Y
hamara professor kaisa ho !!! harry bhai jaisa ho!!!!
13:28 yes.. we can access y from derived.
Harry Sir You are great Sir❤❤❤........