C++ OOP (2020) - What are constructors and class methods? How to use them?

preview_player
Показать описание
In this video, I'm explaining when, why, and how are constructors and class methods used.

📚 Learn how to solve problems and build projects with these Free E-Books ⬇️

Experience the power of practical learning, gain career-ready skills, and start building real applications!
This is a step-by-step course designed to take you from beginner to expert in no time!
💰 Here is a coupon to save 10% on your first payment (CODEBEAUTY_YT10).
Use it quickly, because it will be available for a limited time.

However, please don't feel obligated to do so. I appreciate every one of you, and I will continue to share valuable content with you regardless of whether you choose to support me in this way. Thank you for being part of the Code Beauty community! ❤️😇

"C++ functions" course:

Follow me on other platforms:

*******INITIAL CODE IS IN THE COMMENTS*******
Рекомендации по теме
Комментарии
Автор

📚 Learn how to solve problems and build projects with these Free E-Books ⬇️
Experience the power of practical learning, gain career-ready skills, and start building real applications!
This is a step-by-step course designed to take you from beginner to expert in no time!
💰 Here is a coupon to save 10% on your first payment (CODEBEAUTY_YT10).
Use it quickly, because it will be available for a limited time.

#include <iostream>
#include <list>
using namespace std;

class YouTubeChannel {
public:
string Name;
string OwnerName;
int SubscribersCount;
list<string> PublishedVideoTitles;
};

int main()
{
YouTubeChannel ytChannel;
ytChannel.Name = "CodeBeauty";
ytChannel.OwnerName = "Saldina";
ytChannel.SubscribersCount = 1800;
= {"C++ for beginners Video 1", "HTML & CSS Video 1", "C++ OOP Video 1"};

cout << "Name: " << ytChannel.Name << endl;
cout << "OwnerName: " << ytChannel.OwnerName << endl;
cout << "SubscribersCount: " << ytChannel.SubscribersCount << endl;
cout << "Videos: " << endl;
for (string videoTitle : {
cout << videoTitle << endl;
}

system("pause>0");
}

CodeBeauty
Автор

I've read plenty of c++ ebooks and they are very comprehensible, but your way of explaining class and objects in this video is way more comprehensive. Starting with simple way of creating class and then how you can create multiple classes without having to repeat the same codes. This is better than how I learn it in college. AMAZING 👏

TimelyEnlightenment
Автор

Usually, I don't comment...but after three years of programming and finally understanding constructors I want to say THANK YOU🌸- and I mean it!! Your explanations are comprehensible and finally there's a way for me to understand what I'm supposed to do with all that code. Coffee bought☕

kathrinlahner
Автор

Three years already and your videos are still very useful. God bless you, Saldina

joyceosas
Автор

I am really new with programming. The way you teach by comparing old methods with new one is remarkable !
It make me understand about why it happened and why it matter

Thank you

mudmaster
Автор

i used to dread C++ until i started following this channel. Teaching is a s skill. Thank you so much...

aubreymmotong
Автор

I understood 100%. Now I see the meaning of the constructors. *Thank you so much, Saldina.*

dev.antunes
Автор

currently taking data structures. thank you for this your work is incredible

RainMoneyProductions
Автор

Thank you so much for explaining this, my professor in college blew through this and it's immensely helpful to see your examples! Going to watch this whole series of videos

melody.-.
Автор

Fav songs, wind of change - scorpions, creep - radiohead, every breath you take - the police, drops of jupiter - train.

ashenhewavithana
Автор

I like that you adopt this "show me the problem with something" before you introduce the new concept that was meant to be the solution.

Nathemmanuel
Автор

I just want to say thanks and i just want to let you know that you are making huge difference in many people. love you from ethiopia

natnaelhabtamu
Автор

I really wanna thank you because i am really struggling with C++ and your instructions are so clear and your verbalism, the way you talk is also great and understandable. All these coding videos there's always some guy who is indian and speaking with a terrible accent so i can't really understand from them sometimes (english is my second language) you saved me really! subscribed <3

miaflorida
Автор

Thanks Saldina. It would be great if you could also cover destructors, virtual destructors, delete, and related dynamic memory parts when you have time in future.😀

yuanyuan
Автор

I have to admit that your video is absolutely clear. Thats why I choose to watch your video despite language difference

phungat
Автор

everyone who do such works, give time, and bring such content is worthy to be appreciated, plz bring data structures too.

subratadas
Автор

Thank you so much for these gems. Helps me to become exponentially better in programming, maybe I'll top my branch this semester.

rudradev
Автор

Finally, after some weeks in classroom I am able to get the concepts of OOP. Good work, Salina. Keep going on with more and more videos, sharinh knowledge.

ASandro.AllMat
Автор

you've made programming looks so easy. More power to you girl.

abdullahlahore
Автор

Just stumbled on your site Saldina. Great to see so many C++ videos! Thanks for producing these. :) Looking forward to checking more of these!

WestCoastWanderer