Function-like Macros | C Programming Tutorial

preview_player
Показать описание
Рекомендации по теме
Комментарии
Автор

Your videos on C are the best! I'm guessing only reason people aren't watching your videos because they're usually new to the language and just stick with the shortest and simplest videos out there. But I'm really glad that you're also teaching not so popular topics.

DaiMoscv
Автор

finally found the perfect tutor for learning c programming :)

Unique-mz
Автор

I teach classes about C in my University. Your videos are part of this. Very good content about C. Congratulations.

andredcavalcante
Автор

Wow, this is by far the best C programming playlist I have come across on YouTube. Your teaching style is on point and the explanations are clear. Please keep the good content coming. I am happy that I found this channel. I write code for embedded systems, and we use macros a lot, this was so helpful. Thank you.

gastonkitambala
Автор

Concise and straight to the point, thank you sir

iatomic_
Автор

Loved this video! Learned tons about macros in a very simple and clear way! Thanks man!

vicsteiner
Автор

This is probably the best tutorial on C macros on YouTube! Thank you for the great lesson!
Also could you make a video on how to make makefiles + explain some basic compiler parameters.

Architector
Автор

Quality content! Your explanation is very clear, thanks for sharing your knowledge!

luisvelasquez
Автор

Thank you for this video man!! really straight to the point and just all around good stuff!

edidiongedemeka
Автор

Macros are so much fun. Good call on using the brackets. I actually just wrote my own min max macros and did not enclose them in brackets.

arthur_p_dent
Автор

best C programming channel on youtube:)

DC-oflp
Автор

Thank you for these great vids 👏🏻👏🏻🙏🙏🙏the deeper i get into c the more i understand how valuable these vids truly are

abdlelya
Автор

the best so far ever education in C. Thank you very mush :)

zainalishammat
Автор

Thank you. I am reading a book and was lost. This helps a lot.

michaelpatterson
Автор

I understand why you don’t want to add a “return” @ 17:17. For this example, the return will cause main() to finish. However, I’m a bit confused on why “max_int” sees the final line of the macro @ 18:18? Since the text is getting replaced, why doesn’t “max_int” see “int current_max = array[0];”? I.e., why does it not evaluate to “int max_int = int current_max = array[0];” with the rest of the macro following?

bofa-zifj
Автор

Thank you so much sir for tge time you put into making these nice videos...🎉

Yermehyaw
Автор

If my understanding is correct,

Function like macros are widely used in AUTOSAR architecture to make abstraction between the layers.
(Automotive Domain)

rakurame
Автор

when you define output you attach a semicolon to the end which will result in an empty expression if you put another one at the end of your code

qsmfoui
Автор

When writing a funciton-like macro, ALWAYS place parentheses directly around the variables:

WRONG:
#define mult_by_two(x) (2 * x)
This is wrong because "mult_by_two(3+4)" will be replaced with (2 * 3+4), which evaluates to 10.

RIGHT:
#define mult_by_two(x) (2 * (x))
Now, "mult_by_two(3+4)" is replaced with (2 * (3+4)), which evaluates to 14.

ronald
Автор

doing great job
but ur channel is underrated

TechnoSan