Truly speaking... You won't find anything better than this.. 👍
@sidakrvps5 жыл бұрын
Great teaching method by Neso academy for real learners. Please note preprocessing is done before compiling the code, therefore to get the current time and date by use of __TIME__ and__DATE__ we need to build and run the code each time instead of just running it. Please correct if I am wrong.
@JossinJax3 жыл бұрын
Wow, had no idea you could define functions like that.
@skandeshkkblr3416 Жыл бұрын
The best content one can ever find for c programming... Thanks a ton for the priceless content!
@tayyab.sheikh7 ай бұрын
I regret I missed your videos 😢 ❤ from 🇵🇰
@susanjacob9373 жыл бұрын
For those getting an error for if and else program try this : #include # define max(x,y) if(x>y) \ printf("%d is greater than %d", x,y);\ else\ printf("%d is less than %d",x,y) int main(){ max(5,6); return 0; }
@DurgaPrasad-jr1yl3 жыл бұрын
u have used max two times with same letters plzz use capital at any of that one then it will get
@jabasjabas14342 жыл бұрын
Bro at the final of the else statement / is missing and semi colan is also missing
@ignitedminds6164 Жыл бұрын
I saw a lot of videos about c language .But this channel deserves that place
@deboshreedey23336 жыл бұрын
Your lectures are really very helpful ...thank you for your efforts
@Mr.nikk623 жыл бұрын
your explanation way is so clear, good,understandable
@erichacop30053 жыл бұрын
Brilliantly organized!! Thank you to you!
@victor_zsasz2 жыл бұрын
information overload..idk why we pay so much to colleges.Thankyou sir!!!!!!
@ABDULRAZZAQ-yk7gf3 жыл бұрын
sir, I don't know English, but I understand it easily.
@srikarrepaka50233 жыл бұрын
0:12 0:21 2:16 3:01 4:25 5:03 5:36 6:30 8:02 8:23
@akkasanisreelatha32822 ай бұрын
Best explanation
@opst17044 жыл бұрын
Tips 1. Don't add semicolon at the end ; ❌ 2. USE CAPITAL LETTERS 3. We can use functions 4. There are predefined macros like ___TIME___ and ___DATE___ edit: had to add one more _ because KZbin makes text cursive if you use two __ at the beginning and at the end of a word
@pradhanan94133 жыл бұрын
You can add multiple lines by /
@rakeshraj47866 жыл бұрын
the best lecture on youtube......
@brajanxholaj97673 жыл бұрын
thanks legend
@compangit1524 Жыл бұрын
Comment to myself: Review preprocessors. Define constants thru #define or const keyword. Like so, #define NAME value. NAME is also called Macro. We can use Macros like functions. We can use \ for multiple lines. With macros used as functions they expand explicitly, meaning they are injected in the code and then implemented. Macros like functions don't evaluate within itself. There are default macros like __DATE__ and __TIME__
@apnagallery88703 жыл бұрын
Best explanation 💥
@-MustakimMusa6 ай бұрын
#include #define ADD(x,y) x+y int main() { int var=3; printf("addition of two numbers %d ", ADD(3,4)); return 0; }
@cm-106murali32 жыл бұрын
Last lo time date progarm printf lo ℅s anduku icharu time date lo integers kuda vunai kadha
@014-neerajajadhav32 жыл бұрын
Sir in the first example %5f means after decimal 5 digits will be given as out puts
@gkushwanth22772 жыл бұрын
excellent information about macros
@thureinlinn17892 жыл бұрын
Your explanations are clear and understandable for a beginner like me . May I know the background music at the end of the video,Sir?
@TechAndFunWithAkash5 жыл бұрын
there is an error in #define greater(x,y) if(x>y) \ printf();\else\printf();......................it would be like..#define greater(x.y) if(x>y) printf();\else\printf();
@sandeshadhikari28894 жыл бұрын
@Nadeem Afzal did t work again
@khatariinsaan52843 жыл бұрын
@@sandeshadhikari2889 YES I have also tried
@cherryson46253 жыл бұрын
Play games..Nahhhh Watch NESO academy lectures... Yayyyyyy
@clashbegins20632 жыл бұрын
How it is solved? # define add(s,y) s+y/ s-y int main(){ printf("%d",5*add(3,7));
@madhavikatta73465 жыл бұрын
Sir pls upload array, pointers
@Abdulrahman-uk9ny5 жыл бұрын
+1
@vonucabage14834 жыл бұрын
superb! thankyou
@LogoSystemCG Жыл бұрын
to write mulitple lines, it's not slash but back slash actually. (not the same ^-^)
@abdullahalmamun84764 жыл бұрын
Super 👌👌
@anaghapc88725 жыл бұрын
Sir while using \ output becomes error .Here in main() printf is not used.
@bhoomikashetty39693 жыл бұрын
Just awesome teaching 👍👍👍
@sudipsarkar14003 жыл бұрын
Awesome video sir
@amrnassar36184 жыл бұрын
thanks
@kostavsheoran15305 жыл бұрын
I have a doubt , when you wrote #define add(x, y) x+y , the pre processor is going to replace x+y wherever add(x, y) is written , but when yo wrote add(5, 6) , why did it replaced it to 5+6 , how did it know x,y were variables?
@ArjanvanVught4 жыл бұрын
x and y are not variables. They are substitution names. Moreover, it should be #define add(x, y) (x+y)
@hariharasudhans7828 Жыл бұрын
Mass bro
@Godl_Damon3 жыл бұрын
Sir what about prefixes and suffixes
@RATANAGARWALITINFORMER2 жыл бұрын
thx
@vamsikrishna23164 жыл бұрын
can we return values from macro functions...?
@md.arifulislam23393 жыл бұрын
What is actually our university doing? They should suggest neso academy and sleep.
@reezyyy88004 жыл бұрын
1:59 does anybody know why it says printf("%.5f", PI) instead of just saying printf("%f", PI)? I mean what's the difference??
@dhruvrajkotiya4 жыл бұрын
%.5f means it will round off value or you can say that it consider a value up to 5 decimal places after the point for example value of pi = 3.14159265358979323846 if we print using printf("%.5f",pi); then out put will be 3.14159
@reezyyy88004 жыл бұрын
@@dhruvrajkotiya alright, thank you very much!
@NNELATURIASHOKKUMAR4 жыл бұрын
it means that pi value should be printed 5 decimal values after decimal point
@aditisharma51923 жыл бұрын
Why he use f instead d like before section he use everywhere %d why here he use f instead of that please answer
@ritikshrivastava64263 жыл бұрын
@@aditisharma5192 %d is a placeholder for variables having integer values, %f is a placeholder for variables having float/decimal values, similarly %s is for strings etc etc check out the prev videos in this playlist for the whole list of placeholders
@Manster-minds3 жыл бұрын
Gold
@true41894 жыл бұрын
Thank u
@nimisharawat99493 жыл бұрын
Sir u r the bestttt
@NoName-vg8vf4 жыл бұрын
why PI is a float type variable??
@chaitanyanagasundarakc31634 жыл бұрын
why we need %s to print the current time and current date.what does %s indicates ?is it string specifier or other else
@manasgoel73514 жыл бұрын
%s indicates that the value is a string of characters
@stardust86473 жыл бұрын
@@manasgoel7351 so why we are not putting string headerfile?
@shathyanettem472 жыл бұрын
Sir, can't we use that constant value in variables?
@sulekhaprasad65545 жыл бұрын
Why did u use "%s" in predefined macros while the result is decimal
@peddireddyvaishnavi70275 жыл бұрын
That is %5f which means 5 numbers after point
@kristinasimonova2236 Жыл бұрын
How Programm knows which data type is defined in macro? we don't mention data type in it: #define PI 3,14...
@tanaykamath14154 жыл бұрын
Sir when you printed the value of PI why did we get a white space after it,you didn't add any !??
@arkknight1123 жыл бұрын
is used for printing the statment in next line
@ritiksaxenaofficial5 жыл бұрын
dope explanation👌
@2kthilip602 Жыл бұрын
Why do we use %s at the last program where we use predefined macros
@rupaknath69005 жыл бұрын
Nice
@luffydono0 Жыл бұрын
date;- 15 july 2023 reached on constant
@jagadeeshkattiri19134 жыл бұрын
can we place two underscore at a time
@Godl_Damon3 жыл бұрын
Yeah
@jaswanthkaandagatlla43944 жыл бұрын
date and time was showing wrong
@gunjanlakhlani2 жыл бұрын
There is an error in his explanation regarding macro expansion. #define add(x, y) (x + y) is the macro that is defined and then he mentions that the result of printf("result of expression a*b + c is: %d", 5*add(4, 3)) is 23 (because it is 5*4 + 3). This is incorrect as the above macro expands to add(argument1, argument2) = argument1 + argument2 So in the printf statement it becomes 5*add(4, 3) = 5*(4 + 3) = 5*4 + 5*3 = 20 + 15 = 35. Which is consistent with the BODMAS rule. Please keep this in mind.
@anandpriyanshu91102 жыл бұрын
It's #define add(x,y) x+y Here add(x,y) is name of constant and x+y is its value so add(x,y) is replaced with just x+y not (x+y) So the substituted expression looks like- 5*4+3 so the answer is 23.
@codewithmadrine7843 Жыл бұрын
8:19 my time output is not right , is there away like to modify timezones in c?
@yanoski95 ай бұрын
the code at the end doesnot compile on Vs
@Iamthe_harsh11 ай бұрын
can I get notes for this?
@jeffbezos39423 жыл бұрын
How can I define a file?
@mr.rachetphilanthrophist6014 жыл бұрын
#include #define ADD(x,y) x+y #define G(u,v) if(u>v)\ printf("%d is greater than %d ",u,v);\ else \ printf("%d is greater than %d ",v,u); #define E(m,n,p) m-n*p #define F(l,m,n) (l-m*n) int main() { printf("addition of two numbers: %d ",ADD(4,3)); G(4,5); G(5,6); printf("result of expression a*b-c*d is :%d and not :%d",5*E(2,3,6),5*F(2,3,6)); //expand expression as is defined by macro ... //...and follow order of precedence to evaluate expression return 0; }
@mr.rachetphilanthrophist6014 жыл бұрын
i have combined last two three # concepts in single program.Check it's o/p by compiling & running it on IDE.Mark the difference between expression E and F both will give different output (why?).Can we Use same argument x and y for other macros instead of assigning other variables u,v,m,n,l,p etc.
@arvinthathikesav35312 жыл бұрын
Sir please provide notes
@technicalllinone69572 жыл бұрын
Hlo sir Multiple lines code is not working in #define it's showing error