C++ CONSTRUCTORS explained easy 👷

  Рет қаралды 10,301

Bro Code

Bro Code

2 ай бұрын

#constructor #tutorial #explained
C++ constructor tutorial example explained

Пікірлер: 20
@BroCodez
@BroCodez 2 жыл бұрын
#include class Car{ public: std::string make; std::string model; int year; std::string color; Car(std::string make, std::string model, int year, std::string color){ this->make = make; this->model = model; this->year = year; this->color = color; } }; int main() { //constructor = special method that is automatically called when an object is instantiated // useful for assigning values to attributes as arguments Car car1("Chevy", "Corvette", 2022, "blue"); Car car2("Ford", "Mustang", 2023, "red"); std::cout
@lv3234
@lv3234 Ай бұрын
am i tripping? why is this comment 1 year old but the video was posted 2 weeks ago
@draftofspasiba2
@draftofspasiba2 Ай бұрын
​@@lv3234the video was unlisted/private before, after you make it public it will then set a new video date, except for comments.
@misaelsandoval7542
@misaelsandoval7542 Жыл бұрын
Great video!
@Anonymationsthecoolanimator
@Anonymationsthecoolanimator 2 жыл бұрын
Great!
@user-xk7de1jw8g
@user-xk7de1jw8g 9 ай бұрын
Great lesson.
@artemzakharchuk2842
@artemzakharchuk2842 9 ай бұрын
Great lesson❤❤❤ Broooo...🎉🎉🎉
@shadmankhan1969
@shadmankhan1969 Жыл бұрын
thx bro
@esraafadul2929
@esraafadul2929 23 күн бұрын
can you make a vid about the destructors as well 😔, ty
@shervin9561
@shervin9561 7 ай бұрын
Thanks
@AozenDreyar
@AozenDreyar 6 ай бұрын
thank you
@gamsterilyass2952
@gamsterilyass2952 28 күн бұрын
❤❤❤❤
@samsrec6060
@samsrec6060 2 ай бұрын
Create tutorial for golang
@MindMatrixx1416
@MindMatrixx1416 Ай бұрын
one night before semester exam 💀💀
@Dazza_Doo
@Dazza_Doo Жыл бұрын
Wow another thing C++ does better than C# Why do I say that? C++ () standard brackets C# {} used in a new constructor
@theouterspace5285
@theouterspace5285 Күн бұрын
#include class Agent { public: std::string name; std::string role; std::string gender; std::string origin; enum agentRoles {DUELIST, CONTROLLER, INITIATOR, SENTINEL}; static const char* generateRole(agentRoles role) { const char* agentRoleStrings[] = {"Duelist", "Controller", "Initiator", "Sentinel"}; return agentRoleStrings[role]; } static const char* generateGender(char gender) { gender = toupper(gender); switch(gender) { case 'F': return "Female"; case 'M': return "Male"; default: return "Unknown"; } } void generateInfo() { std::cout
@AYSMOKASHI
@AYSMOKASHI 6 ай бұрын
#include class Car{ public: std::string brand = "Vehicle"; std::string model = "Model"; int year; void drive(){ std::cout
@imslippykid8834
@imslippykid8834 13 күн бұрын
WifeCar.Drift()
@danaildoganov
@danaildoganov 4 ай бұрын
#include class Dish{ public: int calories; std::string ingridients; int protein; std::string taste; Dish(int calories, std::string ingridients, int protein, std::string taste){ this->calories = calories; this->ingridients = ingridients; this->protein = protein; this->taste = taste; } }; int main(){ Dish macandcheese(800, "Mac and Cheese", 50, "Yummy"); std::cout
C++ GETTERS & SETTERS explained easy 🔒
6:12
Bro Code
Рет қаралды 8 М.
C++ CLASSES & OBJECTS explained easy 🧍
10:54
Bro Code
Рет қаралды 12 М.
Женская драка в Кызылорде
00:53
AIRAN
Рет қаралды 488 М.
Sigma girl and soap bubbles by Secret Vlog
00:37
Secret Vlog
Рет қаралды 14 МЛН
Heartwarming Unity at School Event #shorts
00:19
Fabiosa Stories
Рет қаралды 23 МЛН
Red❤️+Green💚=
00:38
ISSEI / いっせい
Рет қаралды 84 МЛН
What is INHERITANCE in C++? 👨‍👧‍👧
11:05
Bro Code
Рет қаралды 10 М.
are "smart pointers" actually smart?
9:44
Low Level Learning
Рет қаралды 72 М.
C vs C++ vs C#
2:26
conaticus
Рет қаралды 1,8 МЛН
C++ user defined functions explained 📞
7:24
Bro Code
Рет қаралды 11 М.
31 nooby C++ habits you need to ditch
16:18
mCoding
Рет қаралды 753 М.
Object-Oriented Programming is Embarrassing: 4 Short Examples
28:03
C++ in 100 Seconds
2:46
Fireship
Рет қаралды 1,9 МЛН
НЕ БЕРУ APPLE VISION PRO!
0:37
ТЕСЛЕР
Рет қаралды 371 М.
Это Xiaomi Su7 Max 🤯 #xiaomi #su7max
1:01
Tynalieff Shorts
Рет қаралды 2,1 МЛН
iPhone 15 Pro Max vs IPhone Xs Max  troll face speed test
0:33