realloc() | C Language Tutorial

Поделиться
HTML-код
  • Опубликовано: 30 янв 2025

Комментарии • 81

  • @NareshIT
    @NareshIT  5 лет назад +7

    Please Comment, Subscribe and Click Bell🔔🔔🔔 Icon for More Updates. To learn software course from our experts please register here for online training: goo.gl/HIB0wL

  • @pkclashing3805
    @pkclashing3805 Год назад +1

    It is the best chanel to understand every concept easily

  • @kanakamahalakshmikunderu4052
    @kanakamahalakshmikunderu4052 2 года назад +1

    Super explanation sir mind blowing

  • @molyoxide8358
    @molyoxide8358 4 года назад +11

    Fallen in love by the way Mr. Srinivas teaches.

  • @SunitaSingh-ex7wh
    @SunitaSingh-ex7wh 4 года назад +9

    Sir,, you are the best i have ever learned from.🙏

  • @amnhere
    @amnhere 7 лет назад +41

    @ 10:50, since stack pointer is of integer type, it should be type cast to integer pointer by typing '(int*)'

  • @sarukansegar6976
    @sarukansegar6976 4 года назад +4

    Sir I watched most of your c tutorials videos. Very well explained.
    Thank you very much Mr.Srinivas.

  • @spicydoge3847
    @spicydoge3847 5 лет назад +3

    Amazingly helpful for understanding the concept behind dynamic memory and how to properly use the calloc/realloc functions.
    Major props !

  • @priyankamishra-jp5tn
    @priyankamishra-jp5tn 3 года назад

    Sir you are the best among all other teachers👩‍🏫‍

  • @_kahini
    @_kahini 7 лет назад +15

    damn the best explanation you can find on RUclips :))

    • @b2-mani
      @b2-mani 6 лет назад

      no, my code school

  • @afreenashraf550
    @afreenashraf550 4 года назад

    Sir your video really helped me to learn c language very well... Am very grateful to you sir

  • @malarmathimalar8961
    @malarmathimalar8961 6 лет назад +2

    Nice explanation sir and i am eagarly waiting to your upcoming videos.

  • @siddeshim3549
    @siddeshim3549 6 лет назад +2

    Please vidios upload sequentially and ur my best sir tnx

  • @sgaming8906
    @sgaming8906 6 лет назад +2

    @ 10:50, it should be int*

  • @suganyasuganya2012
    @suganyasuganya2012 6 лет назад +1

    super explanation,sir upload more example of malloc and calloc

  • @nishikantalenka1251
    @nishikantalenka1251 3 года назад

    You are great sir😊

  • @tapanjeetroy8266
    @tapanjeetroy8266 7 лет назад +2

    thanks a lot sir... please upload more videos on strings,graphics and files in c

  • @shanvisuresh7223
    @shanvisuresh7223 8 лет назад +1

    awesome explanation sir can u please post more videos on pointers with function and pointer with structures array pointers

  • @MuruganElumalai
    @MuruganElumalai 5 лет назад +3

    Your all videos are very nice with clear explanations...In this dynamic memory allocation videos, giving the name as stack in example is confusing , because dma uses heap memory and stack is different from heap...so please don't use the name stack in dma...If I am wrong, correct me..

  • @jothishvj17
    @jothishvj17 4 года назад

    You are a hero sir❤️

  • @krishnakumars9488
    @krishnakumars9488 7 лет назад +2

    hi sir,
    your explanations are awesome.Please make a video in arguments in c.
    eg: int main(args,argv[])
    thanks a lot sir.

  • @ksvijayan06
    @ksvijayan06 4 года назад +2

    10:51 why sir u don't typecaset the void* into int* realloc() ....... The type of stack is Int*.. But we try to store void *

    • @rajkumarseelam9222
      @rajkumarseelam9222 4 года назад

      Yes bro

    • @ballaveeravenkateswararao201
      @ballaveeravenkateswararao201 3 года назад

      He said that implicit typecasting is done .i.e void* is converted into int* or float* type without manual help depending on the data we reallocate

  • @vashishthasiyaram7807
    @vashishthasiyaram7807 4 года назад +5

    While using realloc function, instead of:
    stack= (void*) realloc(stack,capacity*sizeof(int));
    It should be:
    stack= (int*) realloc(stack,capacity*sizeof(int));
    Right?

    • @MOTARD_
      @MOTARD_ 4 года назад

      yes because return type of realloc() is already void* and it needs to be type casted into the required data type (int* in this case).

  • @DewanandSahu01
    @DewanandSahu01 7 лет назад +10

    please arrange videos sequentially

    • @karankhajuria2437
      @karankhajuria2437 7 лет назад

      if you have found the previous one please let me know

    • @vibe_wit_y
      @vibe_wit_y 5 лет назад +1

      @@karankhajuria2437 ruclips.net/video/pTXvkLlAm38/видео.html

  • @Akashkumar-td4vi
    @Akashkumar-td4vi 7 лет назад +1

    good teaching

  • @linhngoc1127
    @linhngoc1127 3 года назад

    tiếng Anh mình hơi ngu mà nghe vẫn hiểu, tuyệt vời

  • @parekhkunjtusharbhai7440
    @parekhkunjtusharbhai7440 3 года назад

    Sir thank you for this wonderful video. I have one doubt that can I use data type(any) instead of void pointer in realloc function at a time of final data type allocation to realloc function

  • @srijithkaladharan5716
    @srijithkaladharan5716 7 лет назад +2

    Hello Sir, We should typcast the realloc() to integer pointer type right? you have done it to the default void type.

  • @SrinadhVibesandBites
    @SrinadhVibesandBites 4 года назад

    Super sir🥰🥰🥰🥰

  • @RAHULYADAV-zr5fq
    @RAHULYADAV-zr5fq 3 года назад +1

    Dear sir,Kindly make a video on free function .i am highly confused.

  • @navyar7653
    @navyar7653 4 года назад

    Sir ,stack=(void*)realloc(stack,capacity*size(int));
    In above statement what will if we return int*

    • @kitchencampers5386
      @kitchencampers5386 4 года назад

      We should return( int* ) sir taught mistake there

    • @navyar7653
      @navyar7653 4 года назад

      @@kitchencampers5386 yes, after typecasting we should return (int*) right..

  • @rameshanantavarapu3866
    @rameshanantavarapu3866 7 лет назад +1

    thank you sir

  • @manishkumarmahato2481
    @manishkumarmahato2481 2 года назад

    SIr, in realloc we always going to use void * ?

  • @ГерриПитт
    @ГерриПитт 5 лет назад +1

    thanks a lot!!!

  • @prudhvipadala3603
    @prudhvipadala3603 4 года назад +2

    sir,we need to int* in type casting of realloc right? why did you use void *? can any one please explain

  • @m.s.3346
    @m.s.3346 6 лет назад

    Good job! Thanks!

  • @omkarsapte4119
    @omkarsapte4119 4 года назад

    Sir calloc function returns the 0 value inside the address block then how 10 20 are stored..

  • @eprasad3519
    @eprasad3519 6 лет назад +2

    Then why cant increase or decrease on structure by using malloc

    • @tenmeh
      @tenmeh 5 лет назад

      in structure you do not define the size, you can take as many elements in a structure as you want.

  • @devirayudu2703
    @devirayudu2703 7 лет назад

    Hi srinivas sir I didn't find if block class and if else ladder class videos so Pls upload it

  • @sandeepkumawat9188
    @sandeepkumawat9188 6 лет назад +28

    Sir i wanna ask something to you
    Sir who is naresh.

  • @pradeepkumarsingh6964
    @pradeepkumarsingh6964 5 лет назад

    thnk u sir

  • @samChakravartiSamrat
    @samChakravartiSamrat 6 лет назад +4

    Srininivas sir explains better than saurabh shukla sir!!

  • @rebhuroy3713
    @rebhuroy3713 6 лет назад +1

    hey sorry for kind of different post in this video but still.wanna know prerequisites of Android P with Machine learning please let me inform..thanks and best wishes for diwali..

  • @adityahridyam7698
    @adityahridyam7698 4 года назад

    what about free function?

  • @tejasshahade2088
    @tejasshahade2088 4 года назад

    Sir, I want to know who is naresh

  • @n.s.manoharbole4981
    @n.s.manoharbole4981 6 лет назад

    what will happen if address 1056 location is not free ? i mean is this continous allocation or not?

  • @pranavsingh9284
    @pranavsingh9284 5 лет назад

    sir cant we change the value of capacity from 5 to 6

    • @Aspired8886
      @Aspired8886 3 года назад

      Same doubt bro.... why dont we simply change the value from 5 to 6...why to use another function for that

  • @reddy9725
    @reddy9725 4 года назад

    Free function u did not uploaded sir

  • @purnendumondal118
    @purnendumondal118 4 года назад

    🙏🙏🙏

  • @AmanKumar-ph4my
    @AmanKumar-ph4my 6 лет назад

    introduce perl tcl tutorial like this .
    give some script ing examples

  • @ankitkumarojha7510
    @ankitkumarojha7510 2 года назад

    thnk u sir