C function prototypes 🤖

  Рет қаралды 47,998

Bro Code

Bro Code

2 жыл бұрын

C function prototypes tutorial example explained
#C #function #prototype
void hello(char[], int); //function prototype
int main()
{
// function prototype
// WHAT IS IT?
// Function declaration, w/o a body, before main()
// Ensures that calls to a function are made with the correct arguments
// IMPORTANT NOTES
// Many C compilers do not check for parameter matching
// Missing arguments will result in unexpected behavior
// A function prototype causes the compiler to flag an error if arguments are missing
// ADVANTAGES
// 1. Easier to navigate a program w/ main() at the top
// 2. Helps with debugging
// 3. Commonly used in header files
char name[] = "Bro";
int age = 21;
hello(name, age);
return 0;
}
void hello(char name[], int age)
{
printf("
Hello %s", name);
printf("
You are %d years old", age);
}

Пікірлер: 25
@BroCodez
@BroCodez 2 жыл бұрын
#include void hello(char[], int); //function prototype int main() { // function prototype // WHAT IS IT? // Function declaration, w/o a body, before main() // Ensures that calls to a function are made with the correct arguments // IMPORTANT NOTES // Many C compilers do not check for parameter matching // Missing arguments will result in unexpected behavior // A function prototype causes the compiler to flag an error if arguments are missing // ADVANTAGES // 1. Easier to navigate a program w/ main() at the top // 2. Helps with debugging // 3. Commonly used in header files char name[] = "Bro"; int age = 21; hello(name, age); return 0; } void hello(char name[], int age) { printf(" Hello %s", name); printf(" You are %d years old", age); }
@krlo5574
@krlo5574 5 ай бұрын
I'm not gay, but I love you bro sincerely from the bottom of my heart. You and Organic Chemistry.
@briankepha
@briankepha Жыл бұрын
Short , precise and to the point , Damn bro
@robertdeckard2136
@robertdeckard2136 Жыл бұрын
I know right, usually with these types of videos, it's half an hour long, covers the entire history of programming, and the fifteen relevant seconds are somewhere around the 23-minute mark.
@melaniediel7540
@melaniediel7540 2 жыл бұрын
this was so clear, thank you!!
@manhcot
@manhcot 2 жыл бұрын
your typing skill is insane !!😦😦
@user-ef2cl9ke9q
@user-ef2cl9ke9q 2 жыл бұрын
Very helpful
@dominicdaculiat851
@dominicdaculiat851 2 жыл бұрын
thank for helping me understand..
@robinpage2730
@robinpage2730 2 жыл бұрын
Please do a video on how to create your own library file that you can #include in your programs
@jimbao9760
@jimbao9760 9 ай бұрын
i got my c exam in few hours thanks
@Abisheganathan
@Abisheganathan 8 ай бұрын
All the best 💯
@seif7653
@seif7653 Жыл бұрын
Thank's bro
@rintugayen2435
@rintugayen2435 Жыл бұрын
Love from india ❤️❤️✌️✌️
@omkarmane4510
@omkarmane4510 2 жыл бұрын
amazing......
@colincazho9725
@colincazho9725 Жыл бұрын
Hey, how are you able to run the program without first declaring "hello" function before main. Whenever I try to do that, I get a function declaration error. Thanks!
@sohailsherkar7770
@sohailsherkar7770 7 ай бұрын
i know its been a year since u commented but when you were declaring the variables did u add [] to make it an array cuz t hat might be the problem.
@PSIwolf39
@PSIwolf39 7 ай бұрын
Here's some code I made for practice: #include #include #include #include #include double power(double, double); int main(){ double result; double baseNumber; double addedNumber; printf("This is the addition calculator program, what is the base number? "); scanf("%lf", &baseNumber); printf(" What would you like to use as the added number? "); scanf("%lf", &addedNumber); result = power(baseNumber, addedNumber); printf(" Your result is: %.1lf", result); } double power(double base, double additionalNumber){ return base + additionalNumber; }
@zakariyedaauud5527
@zakariyedaauud5527 2 жыл бұрын
Thanks sir
@TheScissorunner
@TheScissorunner Жыл бұрын
I like how you speed up the video when you're typing.... right!?!
@1rand967
@1rand967 Жыл бұрын
عجزت افهم ليش نحط شي فوق وشي تحت
@bilaltoumir4475
@bilaltoumir4475 2 жыл бұрын
We use C lang in the first year please put more content about C , nd I'll be much appreciate
@Mad-Ramx_Dev
@Mad-Ramx_Dev 3 ай бұрын
hi
@justcallmeq8120
@justcallmeq8120 3 ай бұрын
I need a count++ for every time you say == function
@bayazidbelkhir5316
@bayazidbelkhir5316 2 жыл бұрын
onbhjh
@Mad-Ramx_Dev
@Mad-Ramx_Dev 3 ай бұрын
hi
C string functions 🔠
5:03
Bro Code
Рет қаралды 57 М.
you will never ask about pointers again after watching this video
8:03
Low Level Learning
Рет қаралды 2,1 МЛН
Slow motion boy #shorts by Tsuriki Show
00:14
Tsuriki Show
Рет қаралды 10 МЛН
Secret Experiment Toothpaste Pt.4 😱 #shorts
00:35
Mr DegrEE
Рет қаралды 37 МЛН
Playing hide and seek with my dog 🐶
00:25
Zach King
Рет қаралды 36 МЛН
Learn Any Programming Language In 3 Hours!
22:37
Code With Huw
Рет қаралды 302 М.
What is a function prototype in C
4:38
Jacob Sorber
Рет қаралды 16 М.
C pointers explained👉
8:04
Bro Code
Рет қаралды 154 М.
how Google writes gorgeous C++
7:40
Low Level Learning
Рет қаралды 837 М.
Function Prototypes -- C++ Functions for Beginners [Part 3]
14:26
Professor Hank Stalica
Рет қаралды 1,4 М.
String In Char Array VS. Pointer To String Literal | C Programming Tutorial
9:58
Call By Value & Call By Reference in C
8:34
Neso Academy
Рет қаралды 1,3 МЛН
C++ user defined functions (#15) 📬
17:14
Bro Code
Рет қаралды 32 М.
C structs 🏠
4:12
Bro Code
Рет қаралды 186 М.
Nokia 3310 top
0:20
YT 𝒯𝒾𝓂𝓉𝒾𝓀
Рет қаралды 3,8 МЛН
Better Than Smart Phones☠️🤯 | #trollface
0:11
Not Sanu Moments
Рет қаралды 17 МЛН
low battery 🪫
0:10
dednahype
Рет қаралды 1,7 МЛН
Look, this is the 97th generation of the phone?
0:13
Edcers
Рет қаралды 8 МЛН