• @JusticeForPorygon
    link
    349 days ago

    Just started uni and theyre having us learn C

    It’s only been a couple weeks and it’s not too bad, but every time I bring up to someone that I’m learning C they express sympathy, which makes me think I’m eventually gonna hit a brick wall of a learning curve.

    • @[email protected]
      link
      fedilink
      48
      edit-2
      9 days ago

      It’s mostly because C is notorious for not holding your hand and not telling you when you mess up. Write one past the array’s length? Might do nothing, might crash, might mess up some other data, might crash later in somewhere completely different.

      • @JusticeForPorygon
        link
        149 days ago

        I spent 30 minutes looking over my code because I forgot a semicolon after defining an integer :(

      • @[email protected]
        link
        fedilink
        148 days ago

        Or in some cases might crash 8.5 million computers worldwide.

        Yes the Crowdstrike crash was caused by going 1 past an array length, caused by a magic number index and a regex mistake, and wasn’t caught because the tests didn’t work.

        The whole thing was a compound series of amateur mistakes, but with kernel access at boot time.

    • @sandalbucket
      link
      259 days ago

      It’s really not bad, you just have to rememb

      Segmentation Fault - Core Dumped

    • @zib
      link
      English
      14
      edit-2
      9 days ago

      C isn’t all that bad once you understand the incredible power you can wield with it. It’s more limited than C++ due to lack of proper OOP, but still very usable and nice to know as a foundation to C++ and other languages. I’ve been rocking both for the last 20 years and they’re still my favorites to use.

    • @sabin
      link
      18 days ago

      Honestly C imo is not that bad. It’s actually a very small specification. There’s not much to it. The actual amount of code you’d need to create a working C compiler is relatively tiny.

      It stuck around all this time because concepts like null-terminated strings, arrays decaying to pointers, etc. are all very intuitive if your working in a language that’s built to be as minimalistic and simple as possible.

      If you understand these things I’d say you’re already past the learning curve. Now just make sure you remember exactly how type definitions are parsed so that contrived type declarations don’t cause you to lose marks on an exam.

      The difficulty with C imo comes with people needing programming concepts abstracted away from them because they never actually learned how their computer represents or processes data.

  • @TallonMetroid
    link
    English
    109 days ago

    It figures that the one time Detect Mimic really was a false positive, she got a C textbook out of it.

  • Rose Thorne(She/Her)
    link
    fedilink
    59 days ago

    Don’t mind me, I’m just setting up the popcorn cart for when the programmer arguments start. I’ll share.

    • @greedytacothief
      link
      69 days ago

      I really want to make a joke about C, but I’m not a very good programmer. Maybe:

      “A magical tome that makes you feel insecure.”

  • @desertdruid
    link
    39 days ago

    That book was a godsend for me in university

  • @frankgrimeszz
    link
    English
    18 days ago

    C is fine. C++ will make or break you.