Intro to Classes and Objects: Coding Tutorials by Umar Khan

Publié le: 26 février 2022
sur la chaîne: Coding Tutorials by Umar Khan
36
4

In this video of the series, we will introduce classes and objects. You may have heard about classes and object-oriented programming (OOP), and the basic idea is that we can write more complex and powerful programs by mimicking the real world in the logic of programming.

For example, with the OOP paradigm, you could create a Player class for a video game. Then, whenever you create an object of the player class, that object will automatically behave in ways that all players behave. When the game controller is pushed up, for instance, the player is animated a certain way and its position on the screen is advanced in the direction defined by an upward movement on the controller.

There is much to learn about objects and classes, and this video will get us started. This is an incredibly important and powerful topic in programming that is applicable to many programming languages, such as Java, C#, C++, Swift, Kotlin, Python, and many more.

Not all programming languages are object-oriented, which I will explain in the video (C is a good example). But Java is, and we are beginning with Java in this video series, so, we will be able to learn about classes and objects as we build applications.

Finally, the code you will write in this video is also available in final form at the link below. If you accidentally delete the code you wrote or it doesn't work for some reason, you can download the three .java files at the link to create your project again (Point.java, Rectangle.java, and BuildRectangle.java).

Note that I will use the files at the link below as the starting point for the next video. Enjoy, post comments, and have fun!

---------------------------------------

https://github.com/u-khan-dev/java-cl...


Sur cette page du site, vous pouvez voir la vidéo en ligne Intro to Classes and Objects: Coding Tutorials by Umar Khan durée heure minute seconde en bonne qualité , qui a été Téléchargé par l'utilisateur Coding Tutorials by Umar Khan 26 février 2022, Partagez le lien avec vos amis et connaissances, sur youtube cette vidéo a déjà été regardée 36 fois et il a aimé 4 téléspectateurs. Bon visionnage!