Just enough C to have fun

Поділитися
Вставка
  • Опубліковано 24 лис 2024

КОМЕНТАРІ • 168

  • @Kelsu_
    @Kelsu_ 3 місяці тому +78

    One of the best C classes that i have seen in my whole life, way better than the college classes i attended. I apreciate

    • @neoeno4242
      @neoeno4242  3 місяці тому +5

      Thanks :)

    • @Michaelno
      @Michaelno 24 дні тому

      Ok first comment, i'm about follow along. we will see :)

  • @ProVrakian
    @ProVrakian 3 місяці тому +40

    Thank you for treating your audience like adults. This is the right amount of fast-paced and insightful.
    I appreciate a video that is meant to inspire people to dig deeper.

  • @maxmustermann5590
    @maxmustermann5590 17 днів тому +3

    Man I knew this stuff and still watched it to completion. You have a lovely style presenting and I could listen to you talk about nerdy topics all day

  • @Artem1I9a
    @Artem1I9a 3 місяці тому +8

    The best explanation of how memory works that I've ever seen. Very clear. Thanks for your effort.

  • @ivankevamo
    @ivankevamo 3 місяці тому +47

    Great job. I have to thank the youtube algorithm for suggesting your channel. Thanks a lot. Greetings from South America.

    • @djianstankovich100
      @djianstankovich100 3 місяці тому +1

      i agree with you and my greetings from Egypt 👏💪

  • @laxmanneupane1739
    @laxmanneupane1739 Місяць тому +1

    Just watched this. The density of information is quite spot on.

  • @simonegalli5453
    @simonegalli5453 2 місяці тому +2

    The step by step visualization of all the memories involved was reslly well done. Thank you to spread knowledge.

  • @Humble_Electronic_Musician
    @Humble_Electronic_Musician 3 місяці тому +21

    The content and presentation is top notch.
    I also like your eloquent speech: I'm interested in low level programming, but even if i was not, I would probably listen to this vid.

  • @kscd009
    @kscd009 3 місяці тому +5

    Gold mine of content. This deserves much more audience

  • @LuzHarlott
    @LuzHarlott 2 місяці тому +1

    Thanks for the video! I haven't used C in years and had forgotten how fun it is, this will be a great refresh for me :)

  • @4xl45cd
    @4xl45cd Місяць тому

    I came across the training series on C/C++ from sharing developments on different sites. I'm glad I came across it. There are many training series on C programming language, but none of them are as detailed and connected as you described. Thank you for your efforts. Greetings from Turkey. Good work.

  • @andrewwdavid
    @andrewwdavid 27 днів тому +2

    honestly such a refreshing video on C,

  • @pavalep
    @pavalep 2 місяці тому +2

    kay..thanks for this awesome series. Im a react native developer who is interested to learn thee nitty gritty of coding. but actually lacks the core concepts. will be following ODES series as i find the videos very enlightening👍

  • @caesarespinosa3131
    @caesarespinosa3131 Місяць тому

    Magnificent classes you give Dear Kay, most grateful to you and thanks for your efforts

  • @goingupandupandup
    @goingupandupandup 2 місяці тому

    This is the best lesson on C I have ever watched. Thanks a bunch

  • @GreeneThumbs
    @GreeneThumbs 3 місяці тому +2

    I've recently started learning C, and this video is perfect. I really like the format and presentation. Thank you!

    • @50lek
      @50lek 3 місяці тому

      I need to learn C++ for work, and its also really complicated in my opinion. What do you think?

  • @obrikash9123
    @obrikash9123 3 місяці тому +1

    I really enjoy your videos as i had some experience with c++ and i almost understand all of just C. I think this video format is great for people who are already informed about basics, pointers and memory concepts. Love from Moscow, Russia

  • @gepacc
    @gepacc Місяць тому

    Some of the best programming content on UA-cam!

  • @chowder9576
    @chowder9576 3 місяці тому +2

    I randomly saw this on my UA-cam feed and so glad I watched. I don't even code in C but it was interesting learning something new! I hope to see more videos! :)

  • @lautarolopez9992
    @lautarolopez9992 Місяць тому

    Your content is PURE GOLD Kay, thank you!

  • @riebeck1986
    @riebeck1986 27 днів тому +1

    Great video ! So much information, but is so well presented and clear !

  • @axelqt1
    @axelqt1 Місяць тому

    Thanks a lot for this, others would have taken at least 4 hours for this amout of information, really appreciate it

  • @NerdyX90
    @NerdyX90 День тому

    You are a fantastic teacher... thank you for this..

  • @hasanhuseyinyurdagul5403
    @hasanhuseyinyurdagul5403 3 місяці тому +1

    The presentation and whole video overall was very smooth, even though I already knew this stuff, I watched until the end. Subscribed, very good content.

  • @charlesmarseille123
    @charlesmarseille123 3 місяці тому

    the explanation of the function pointer in the memory space is great. well done.

  • @calengo454
    @calengo454 Місяць тому

    hello i love you this is literally the best c video on the internet

  • @UliTroyo
    @UliTroyo 3 місяці тому +11

    C really is fun! And because it's been around for so long, used textbooks on Amazon are dirt cheap.

    • @stefanalecu9532
      @stefanalecu9532 3 місяці тому

      I don't see you making the same argument for Fortran and Pascal ;)

  • @modolief
    @modolief 3 місяці тому +1

    Good explanatory content for beginning C programmers.

  • @MrAguaconazucar
    @MrAguaconazucar 2 місяці тому

    This is a work of art. Keep up with the good job. Im thankful for this resource

  • @devoiddude
    @devoiddude 3 місяці тому

    I have a background in java and actually started in C last week, was openai to help me show examples etc but this video was very helpful, thanks so much!

  • @deutschWallah
    @deutschWallah 2 місяці тому +1

    Hey Kay, this is really good class. I hope you take more of such classes, maybe involving more of gdb and valgrind and other mess which we usually face 🙂 Really really good work.

  • @dixztube
    @dixztube 3 місяці тому

    Just had to comment again and I’m a new subscriber. This was so good. You’re very intelligent and explain things well. Made all this seem very easy

  • @AnimeKing-m2t
    @AnimeKing-m2t 3 місяці тому

    Such an amazing talk...pure code and explanations.

  • @adekorir
    @adekorir 3 місяці тому +1

    perfect for my reintroduction to the c programming language.

  • @kriszenn1125
    @kriszenn1125 2 місяці тому

    The for-loop is syntactic sugar for a while loop with the following setup:
    initialization;
    while (condition) {
    increment;
    }
    and its equivalent for-loop
    for (initialization; condition; increment) {
    }
    EDIT: i think it's easier to think of a for-loop as:
    for (before; during; after) {
    }
    but that can be confusing too. "During" is the condition that is technically checked *before* running the , but one can say that it's constantly being checked *during* the loop. "Before" is self-explanatory, but "after" seems confusing. "After" is code run after the has done its thing.

  • @cincooitodois
    @cincooitodois 3 місяці тому +1

    youre awesome, kay! learning a lot from you. thanks!

  • @onurolce
    @onurolce 2 місяці тому

    What a calm person you are !:) First time I've watched your video. So let me check your playlists :)

  • @SuncoastSoftware
    @SuncoastSoftware Місяць тому

    I wish you taught c#, I love the way you "teach".

  • @veto_5762
    @veto_5762 3 місяці тому

    I don't even know why I'm watching this since I've been using c++ for like 3 years now, still nice video

  • @1732ashish
    @1732ashish 3 місяці тому

    thanks for this crisp, to the point video.

  • @codephilosopher
    @codephilosopher 3 місяці тому

    Thank you, your videos are very enjoyable to watch.

  • @ItsRyanStudios
    @ItsRyanStudios 3 місяці тому

    I've been having a crisis of meaning lately; I love my work as a web dev, but every day I'm just writing bloat.
    I was looking for a good intro to C or embedded development; grateful the algorithm sent your channel to me 👍

  • @dominichawkins7997
    @dominichawkins7997 2 місяці тому +1

    Poor hand writing is a sign of intellect':] You rock!

  • @MarianoBustos-i1f
    @MarianoBustos-i1f 3 місяці тому

    This comment works roughly as you would expect it: you make an awesome video, I comment nice stuff.

  • @nazneenzafar743
    @nazneenzafar743 3 місяці тому

    Thanks for the lesson. I hope you keep up with producing awesome content.

  • @bradmccoy1747
    @bradmccoy1747 3 місяці тому

    I enjoyed this video. I liked how you connected everything together. I am a less than beginner level in C. I have been in Assembly for quite a while now. I have have bounced into all of these concepts during my own writes and you lay it out so nicely and I like how it doesn't have to be fast and skippy. The whole concept of a function returning data has bothered me for some time now. The concept is an abstraction from what is really happening. A function call is really just a sugary goto but with a fancy way to return to the next line after the goto. And when the function does return; it just cannot carry data with it - LOL. But it could have altered the values in the registers. And our ancestors created a fancy trick by altering the RAX (EAX, AX, AL, AH) register; then copying that new value into a variable on the caller side. This gave the illusion in our beloved gen 3 languages that a function may return a value. But it really didn't, it just changed a register value. My point is that now everyone wants to return big stuff from functions and it has just gone too far. Ok - thats my rant for the day. And your video supports my thoughts with realistic examples. Love it!

    • @neoeno4242
      @neoeno4242  3 місяці тому +1

      Thanks for the comment! Really enjoyed reading it. I'm looking forward to getting more into building up the 'function' abstraction through assembly in the next couple videos. Was just playing around with it today actually. Exciting!

  • @offlinemark
    @offlinemark 3 місяці тому

    Great video, thanks! I'm using C to build a little hobby os for fun, and this is a nice refresher video :)

  • @twenty-fifth420
    @twenty-fifth420 Місяць тому

    For better or worse, this is the video I need to see. I am working on a modern immediate GUI for myself, for fun (and maybe 'profit' for as far as I can go with FOSS!).
    Better late then never I suppose!
    Edit: 2:22 *shoves nerd glasses* What you refer to as 'Lie-nuhx' is in fact, 'GNU + Linux' or simply the 'Linux' stack.

  • @latch909
    @latch909 2 місяці тому

    This rules, someone lovely making nice videos about C what could be better

  • @caspersro
    @caspersro 2 місяці тому

    i like your way of giving the information good work really i have a little knowledge of C Language so i may ask you to teach me and others like me C Language like this way
    Thank you in Advance 😍😍😍😍😍

  • @johnsteve1276
    @johnsteve1276 2 місяці тому

    Great content. Appreciate your hard work. Btw, could you make a video about C++ ?!

  • @betoperalta701
    @betoperalta701 2 місяці тому

    You have a nice smoothing voice

  • @ramonasuncionbatista
    @ramonasuncionbatista 7 годин тому

    Great video!

  • @mantra578
    @mantra578 3 місяці тому

    i really had fun watching this

  • @calderarox
    @calderarox 2 місяці тому

    this is a great video! thanks for sharing

  • @4ozmane
    @4ozmane 3 місяці тому

    The clip cuts are nice to keep things moving, keep making educational videos plz

  • @clintquasar
    @clintquasar 3 місяці тому +1

    Great teacher!

  • @z0rba566
    @z0rba566 2 місяці тому

    thank you yt! thank you Kay! can I request for a holy-C playlist !

    • @neoeno4242
      @neoeno4242  2 місяці тому +1

      Just added playlists to my todo list!

    • @Satyam1010-N
      @Satyam1010-N Місяць тому

      ​@@neoeno4242 pdf too, I find enterprise design architecture very hard , basic intermidate is on yt , I wish get to to projects live ( pre record ed)

  • @mrinalyadav4261
    @mrinalyadav4261 3 місяці тому

    this series is grt.

  • @werren894
    @werren894 2 місяці тому

    This is awesome!

  • @bzboii
    @bzboii 18 днів тому

    7:20 aaaand you’ve reimplemented godbolt :)

  • @FocusAccount-iv5xe
    @FocusAccount-iv5xe 3 місяці тому

    This was wonderful. Thanks!

  • @dixztube
    @dixztube 3 місяці тому

    Wonderful job!

  • @Gersberms
    @Gersberms 3 місяці тому

    I really love your style of presenting the source, the structure of your story, and just the easy going nature of it all. I will gripe about using two spaces for indentation, so -1 point for that, but +2 points for showing simple macros so that I now no longer feel that I need to avoid them. Thanks! Oh and, printf is super slow because I believe it's monstrously complex, so that might be worth mentioning (plus security risks I believe). And is make really worth using?

    • @neoeno4242
      @neoeno4242  3 місяці тому +2

      Thanks! And all good points - I can definitely feel the complexity of printf coming through when I reach for it :) Re: make, with these videos questions like that are often a balancing act. Could use a plain shell script but then learners might not remember make at all and that can be confusing later, or could go for something more fully featured and then you're going to also have to include setup instructions and risk diverting attention. My angle is often trying to put people in a position where they've encountered the right set of things to then go build on the basics later - rather than taking a sophisticated approach early on and getting muddled. Could easily argue for other tradeoffs though! Anyway, thanks for the comment :)

    • @Gersberms
      @Gersberms 3 місяці тому

      @@neoeno4242 You're right about make and your approach. This was more of a personal curiosity, and not a comment on your content. I got inspired by Handmade Hero that a batch file or shell script will suffice because usually it's just a few lines of mkdir, copy, gcc and run. So I have come to rely on a simple VS Code "skeleton project" as I clumsily called it that does these things: build, debug, and test. Whatever language I'll use is not even important because the concept works for whatever I'm making.
      You done any video on git yet? VS Code and git are a match made in software heaven.

    • @neoeno4242
      @neoeno4242  Місяць тому

      Not yet! Good idea though, thanks :)

  • @Marc-Tu
    @Marc-Tu 3 місяці тому

    Nice video. And I like your shirt. It looks good on you.

  • @ytbacc0001
    @ytbacc0001 3 місяці тому +1

    Thank you for this video

  • @t1nk3rtail0r
    @t1nk3rtail0r 2 місяці тому

    Very, very good !

  • @salim444
    @salim444 3 місяці тому

    the first this I do in an empty main is allocate 5k array just for the sake of it. Feels great to allocate arrays and then free it

  • @egu00
    @egu00 3 місяці тому

    enjoy your video, thanks!

  • @ru2979
    @ru2979 20 днів тому

    Please make more C videos 😢🙏🏼🙏🏼🙇🏼🙇🏼Please please ❤

  • @Tenshi-sk8ty
    @Tenshi-sk8ty 3 місяці тому +41

    bro is majestic

    • @2wheels2
      @2wheels2 3 місяці тому +1

      bro is trans

    • @thomasredden3159
      @thomasredden3159 3 місяці тому +6

      she is slaying physically and intellectually 💅

    • @bmno.4565
      @bmno.4565 3 місяці тому

      Agreed, what a fierce flow.

  • @josephlagrange9531
    @josephlagrange9531 3 місяці тому

    Hi, I subscribed yesterday.

  • @Marco-pz5dx
    @Marco-pz5dx 3 місяці тому +52

    I liked the video, but honestly probably a bit too hard for beginners. Honorable mission though. In particular, the attempt to simplify some topics may actually end up misleading: on discussion about returning strings, I can see how you really try to explain variables' lifetimes but without mentioning them explicitly only focusing on the example. I would try to instead insist on the notion of lifetime and then go on explaining why callee variables on stack cannot outlive their lifetime and be accessible from parent (i.e. they "expire" upon return, and thus caller's attempt to access that now potentially overwritten stack memory is flawed). I would also showcase how a struct wrapping the fixed size array is possible due to return semantics.

    • @neoeno4242
      @neoeno4242  3 місяці тому +27

      Such an interesting perspective - thanks for sharing, appreciate it and I'm sure others will too.

    • @jamesdoe2139
      @jamesdoe2139 3 місяці тому +1

      @neoeno4242 do you have a Discord server/are you a Discord user?

    • @parallelno
      @parallelno 2 місяці тому +2

      Thank you for the video. Please review the memory dump you're showing. Each line should display 16 bytes, but yours only shows 8. Additionally, please verify the byte order. On most modern architectures, it should be little-endian, meaning the smaller byte appears first.

  • @Isaac-zy5do
    @Isaac-zy5do 3 місяці тому

    At 14:00 i think it should either be nums[0] = 0x10; nums[1]=0x20; etc or 0a 14 1e in memory

  • @uuuweee
    @uuuweee 7 днів тому

    I tried printing junk data just like at 27:04 on my machine using Clang version 14.0.0-1ubuntu1.1, but the data was not junk. When I used GCC, I got a Segmentation fault. After some research, I found that by setting the -fsanitize=address and -fsanitize-address-use-after-return=always flags, it detects stack use and fails. I wonder why I couldn’t print a junk value on my machine.

  • @fazin85
    @fazin85 Місяць тому

    great video :)

  • @PowerLlama
    @PowerLlama 11 днів тому

    "those fast counters will know" lol

  • @estebanmorales9736
    @estebanmorales9736 2 місяці тому

    incredible

  • @seekyou
    @seekyou 3 місяці тому

    watching this quite cool video feels a little bit like stealing for the goodness received for free!

  • @jimshtepa5423
    @jimshtepa5423 3 місяці тому +2

    do you have a map of topics you plan to cover in the next10-15 videos?

    • @neoeno4242
      @neoeno4242  3 місяці тому +7

      Working on it :) At the moment I'm working towards creating binary executables from scratch as a little milestone. That will involve spending a bit more time working with binary data, file formats, syscalls, and ASM. I think my planning will solidify in the next few months - will share more as that solidifies!

  • @christopher8641
    @christopher8641 3 місяці тому

    great! video

  • @VforVanish
    @VforVanish 2 місяці тому

    If the memory is allocated with malloc and returned, if we call printf it wont be corrupted no?
    That problem was because the array was on the stack?
    Very interesting videos an great teacher!

    • @neoeno4242
      @neoeno4242  2 місяці тому +1

      Yes that's correct!
      Though if we use malloc in the function then we will have to decide when to free or 'give back' that memory (since in C nothing will free it up automatically and if the function is called repeatedly this will eventually use up a lot of memory).
      So string functions in C instead typically take a pointer to a buffer as an argument and then alter that buffer. That way the caller is responsible for allocating and freeing memory however they see fit.

  • @rescyy2235
    @rescyy2235 3 місяці тому +3

    What text font are you using?

    • @neoeno4242
      @neoeno4242  3 місяці тому +6

      Largely: Monaspace Xenon for the code font, and Mona Sans for the rest. Sometimes I mix up the monaspace font families though :)

  • @zyhru
    @zyhru 2 місяці тому

    Isn't the second solution with malloc more flexible since there might some situations where you don't know length of the string at compile time?

    • @neoeno4242
      @neoeno4242  Місяць тому +1

      Yes - it definitely has that advantage. Though it has some other disadvantages, for example that allocating memory takes a bit of time and someone has to remember to free it up. Many (not all) C programmers prefer fixed-length buffers to malloc for certain tasks. If you're used to higher level languages this might feel weird though!

  • @manfredbogner9799
    @manfredbogner9799 3 місяці тому

    Sehr gut

  • @energy-tunes
    @energy-tunes Місяць тому

    Very high quality channel

  • @MagicalCritical
    @MagicalCritical Місяць тому

    can we have some cintent on testing (windows) ?

  • @onurolce
    @onurolce 2 місяці тому

    12:46 unsigned char MAX should be +255 , am I wrong ?

  • @DeeBash
    @DeeBash Місяць тому

    @19:55 Is it padding, between two string addresses? exactly at 0x0014 (based on correct addressing).
    if it's not padding then why extra 00 stored in between two strings. I can understand the null pointer at the end of strings, but why extra zero at 0x0014

    • @neoeno4242
      @neoeno4242  Місяць тому +1

      Good question - that one is just arbitrary. I wanted to indicate for the purposes of the demonstration that I'm not describing precisely where strings will definitely get put in memory. The values aren't packed perfectly so that people won't accidentally assume that they are. In the real world, there might be many reasons - could be padding/alignment, could be the C compiler is deciding to store other values there, could be other reasons, or it could be that they get packed perfectly!

    • @DeeBash
      @DeeBash Місяць тому

      @@neoeno4242 thank you for the explanation. I thought C is just like assembly(.align 4). But from your explanation, we can't be sure how data is packed/ordered in memory. I'm sad now.

  • @avizyt_official
    @avizyt_official 20 годин тому

    There are two type of programmers in this world by pronunciation of Linux
    1. Leenax
    2. Lainax
    I'm leenax type and you?

  • @antonio_carvalho
    @antonio_carvalho 2 місяці тому

    Spec requirement: high tech title card. ☑️

  • @sadramohh
    @sadramohh 9 днів тому

    3:47: "Lowercase Zero" xD

  • @sanctuary_of_soul
    @sanctuary_of_soul 3 місяці тому

    at 8:32 i believe there is something off in how the sentence is composed logically.
    "...it just gets inlined straight into the file, and everything in the other C file gets chunked into the C file we are including from..."
    "...chunked into the file we are including from..." does it?
    Or am i missing something?

    • @BoardGameMaker4108
      @BoardGameMaker4108 3 місяці тому

      You are right, that might be a small mistake. For anyone looking at this later, it just does a simple copy and paste (from the other file into your file).
      By convention, we also generally separate code into two files "header files" (.h) contain code that you want to be copied into other files (you can #include them). Implementation files (.c) contain code that you don't want to (or can't) copy around. One thing to note is that you cannot copy function implementations, so leave the implementation in a .c file, and the declaration in the .h file. This lets you use the function in other places without having multiple functions with the same name causing a linking error.

    • @neoeno4242
      @neoeno4242  3 місяці тому

      Yes it's not super clear - thanks for flagging and also to @BoardGameMaker4108 for clarifying. Appreciate it.

  • @jonathansung8197
    @jonathansung8197 Годину тому

    #define HE SHE
    #define HIM HER

  • @ga1agen
    @ga1agen 3 місяці тому

    19:13 - what the hell each 4 bits have its own address? x86 cpus can only address minimum a one byte(8 bit)... and other cpus, except microcontrollers( where part of memory can be 1-bit addressed for gpio)

    • @neoeno4242
      @neoeno4242  3 місяці тому +2

      Ah yes, my mistake - thanks for flagging. I mistakenly gave each digit its own address, which isn't correct! Should be something more like this: link.excalidraw.com/readonly/KooN4ScH7IO4QuRsZtEG

  • @SimGunther
    @SimGunther 3 місяці тому +2

    TL;DW
    Noob: Why does the program segfault? I'm too used to OOP!
    Expert: The stack does too good a job cleaning itself up, which is why you can't just return an array like that in your string concat function.
    Noob: Seriously, why doesn't it work like I expect it to?
    Expert: Because with great memory control comes great responsibility.
    Noob: So I can just make a big array at the beginning of the program and use that instead of worrying about free andMalloc?
    Expert: That's what I do in my prototypes anyway until I find it necessary to allocate such memory by hand.
    Noob: I'll just stick with JS and hope for the best.
    Expert: Wait a minute, you can still leak memory in J-
    Noob: _Sees browser crash due toOOM error_ Thanks anyway, I'll just stick with my abacus. At least that doesn't break on me when I least expect it to...

    • @neoeno4242
      @neoeno4242  3 місяці тому +1

      This is my fave one: ua-cam.com/video/GcDshWmhF4A/v-deo.html

  • @ArthurSchoppenweghauer
    @ArthurSchoppenweghauer 2 місяці тому +1

    thanks bro!

  • @vasantheee
    @vasantheee 3 місяці тому

    Is it possible that the assert without printf could also fail at 25:10 because buffer variable is reallocated to something else? I am not sure why it is stated here that the program fails only after printf is added.

    • @anon_y_mousse
      @anon_y_mousse 3 місяці тому

      Because it's on the stack and the stack is changed after calling printf(). Literally any function which makes use of some stack space would have the same effect.

    • @vasantheee
      @vasantheee 3 місяці тому

      ​@@anon_y_mousse but even without modifying our program, it is possible that stack memory could be allocated or used by some other program and there is no gurantee this program would work everytime (without printf Or any other change) right?

    • @anon_y_mousse
      @anon_y_mousse 3 місяці тому

      @@vasantheee I certainly wouldn't depend on it being valid after the function call, but OS's typically will allocate a stack per thread or process, depending on configuration. However, depending on what the compiler does to your code, even if you don't make a function call, it's likely that data higher up on the stack could be instantly invalidated upon function return. For older chips and microcontrollers, if you have a stack at all, then all parameters would be passed on the stack, generally, and then upon return, anything allocated off the stack inside the function would be instantly invalidated. For newer chips, it's pretty much a given that parameters will be passed by register if you have few enough parameters, but the compiler might very well finagle your code such that it has to push and pop some data around the function call which would thus invalidate the array.
      In short, you don't have to worry about other programs running on the system invalidating your stack because your own program will likely do it without you directly seeing the effects.

    • @vasantheee
      @vasantheee 3 місяці тому

      @@anon_y_mousse thank you. So we cannot count on the program being successful like it happened at 25:10 all the time, right?

    • @anon_y_mousse
      @anon_y_mousse 3 місяці тому

      @@vasantheee I would say we shouldn't ever count on it. The thing to remember, if you want to work with an array, pass it into the function. If you want it to be resizable, then pass the address of the pointer. If you want to do dynamic arrays, then consider using a struct and passing the address of that struct, say typedef struct { size_t length; int data; } array_t; and just replace int with whatever type you wish to have an array of. You could even make the array type something like int_array_t or array_int_t or whatever name you feel like.

  • @richardappow6770
    @richardappow6770 3 місяці тому

    what code editor are you using here?

  • @yanovoyair5129
    @yanovoyair5129 16 днів тому

    computer science is super dense , bruv