anil sir you are the best programming teacher. I am in 7 class and is learning c programming language by you. #include #include int main() { printf("thank you"); getch() return 0; }
@saitejachandolu96297 жыл бұрын
Good luck little brother :)
@subratsinghal10506 жыл бұрын
There's a mistake there should be a ; after getch()..... :-)
@rushikeshpatil29224 жыл бұрын
sir, concepts clear ho gaye..thank you
@LearningLad4 жыл бұрын
Most welcome
@raghavendramani97959 жыл бұрын
Thank you so much.
@rajatgarg94687 жыл бұрын
great work
@rachelh40110 жыл бұрын
in which case i can use pointer?
@WRAND22089 жыл бұрын
Anil you get same address for x and y but i get different addresses.is it okay to get two different address for x and y for the code you wrote.
@TheDoubleg948 жыл бұрын
+WEKRAYS If you're talking about line 12 then make sure you use %p instead of %d.
@muhammadshahryarazhar25717 жыл бұрын
Correction!!! Variable 'j' is storing memory address of variable 'x' (which is right). But at 12:14 he (Sir Anil) said variable 'j' is storing memory address of its own (with all due respect which is wrong).
@malpol7 жыл бұрын
Thank u sir😢
@LearningLad7 жыл бұрын
Pleasure :)
@nagshankar7309 жыл бұрын
you said if we use "*" with x then it will return the value present in that variable,similarly if we use "*" with j,it should return the value in that variable.why would it read its value as the address of the memory? it should return 14286 as its value right? and why didn't it happen in in the case of x variable?
@LearningLad9 жыл бұрын
Nag Shankar dude i don't have the source code for this tutorial. can you give me the code here so that i can explain????
@nagshankar7309 жыл бұрын
how about if send the link of your youtube video?? kzbin.info/www/bejne/r6qUZ4hra6t5jM0
@nagshankar7309 жыл бұрын
let me say "*j" is the pointer to x variable...in general * denotes the value present in it,"*j" contains value present in it right? so it should output the value present in that,but why will it output the value present in x variable?? is it because we mentioned it has as a pointer?? did u get my doubt??
@LearningLad9 жыл бұрын
Nag Shankar consider int x = 10; int *j; lets assume that x variable's memory address is 12345 so in memory address 12345 value of 10 will be stored. here * is used to indicate that we are declaring a pointer. In this case j can contain the address of an integer variable. so when we write j = &x; we are storing the address of variable x in j. i.e j = 12345 now to get the value stored in j, you just need to write printf("%u",j); which will give the address of the variable x i.e 12345. now to get the value pointed by the pointer j ( i.e the value stored at the memory location which is in j or value at memory location 12345) we are gonna write printf("%d",*j); here * is called as value at operator. it will give the value stored at the memory location specified with it. when we write *j we are specifying the memory location which is in j which is nothing but *12345 ( i.e value at the memory location 12345) which is the value of x i.e 10. Hope this helps :)
@nagshankar7309 жыл бұрын
thanks dude..its clear! :)
@rajasangeetha80927 жыл бұрын
Why we can't store two values in same memory. For ex:initial i stored x=10 and then again i written x=20 , the output will be x=20 why like that
@codelikeapro97242 жыл бұрын
if you want to store like x and y at same memory then how will you recognize that a certain value belongs to x or y? means a value can access other variable value.. right? which is not good... to protect it in os we use semaphore.. nd if you take x =10 and then write x =20 then it is modifiying it to 10 to 20 at same memory but only if the x belongs to the same program.. read about os working semaphore and paging concept to know how cpu works and store data!
@sparkden7 жыл бұрын
you removed videos from your web site:) why man?
@himanshuchugh93067 жыл бұрын
why can't we write *y=x in place of x=&y ??
@rdjslovers4 жыл бұрын
code is not available on website
@Escarii669 жыл бұрын
Your accent is quite strong so I turned on subtitles and the results were hilarious! Good video though, tnx.