Why I Like Programming in C.

Поделиться
HTML-код
  • Опубликовано: 15 май 2024
  • It's hard to explain why you like something, isn't it? I still don't feel like I have.
    ...
    Rust will *never* be as based as Haskell.
    [Timestamps]
    00:00 Start
    00:27 I wanted to play the "Link Opening Chest" SFX here. Please imagine it.
    00:58 This is the instruction set I came up with for my bespoke CPU.
    01:20 My solution in C
    02:05 Couldn't figure out what would be a good example for this. cgltf, maybe?
    02:15 Disclaimer: Not An Artist.
    [Links]
    Ken Sherrif's Blog for CPU Images: www.righto.com/2020/05/extract...
    Project Euler Problems: projecteuler.net/archives
    cgltf: github.com/jkuhlmann/cgltf/tr...
    Some list of c++ features: github.com/AnthonyCalandra/mo...
    I like the idea of Haskell: wiki.haskell.org/Zygohistomor...
    I recorded and tried adding a few sound effects. Hopefully they weren't too much.
  • РазвлеченияРазвлечения

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

  • @sturdyfool103
    @sturdyfool103 Месяц назад +39

    I like working in C++ or Rust because they give me the option, which I sometimes choose not to - to take those basic blocks and turn them into the higher level tools that exponentially snowball my journey

    • @Leonhart_93
      @Leonhart_93 2 дня назад

      C++ gives you the option to write in any way, you can even write plain C in it.
      Rust doesn't at all, Rust is not about giving you the "option" to do anything. The whole point is to do it exactly like the compiler wants you to do it. No thanks.

  • @teenspirit1
    @teenspirit1 Месяц назад +36

    I don't love C or anything, but I'm just so happy GCC (and later CLang) exists. We would be up to our necks in corporate BS if those compilers didn't exist or they sucked.

    • @hansdampf2284
      @hansdampf2284 12 дней назад +2

      Just look at the windows world and their msvc and you know how the rest of the world would be like

    • @efka3039
      @efka3039 10 дней назад

      mingw though!

    • @twenty-fifth420
      @twenty-fifth420 9 дней назад

      @@hansdampf2284Installing Visual Studio was enough for me to realize that Microsoft sucks actually with development tooling. No wonder WSL exists.

    • @Anriuko
      @Anriuko 4 дня назад

      @@hansdampf2284 What would it be like?

  • @zen_nabu
    @zen_nabu 6 дней назад +4

    I'm new to C and it was hard to get past the basics but I've found new motivation in the idea that we can truly build anything if we're clever and creative. So cool.

  • @Dev_with_Sel
    @Dev_with_Sel Месяц назад +26

    Great video! Programming in C makes me feel like I'm inside the computer. I'm planning to learn Assembly next to go even deeper

    • @FranciscoFox
      @FranciscoFox  Месяц назад +9

      Nice! It's hard to describe how smooth that transition is--from the computer's internal operation to C.
      If you want to jump to the bottom you could try designing your own CPU. NAND2Tetris is a great resource for that (from what I remember of it). It's a big jump but *does* grant a lot of...perspective.

    • @Dev_with_Sel
      @Dev_with_Sel Месяц назад

      ​@@FranciscoFox Wow, thanks! I'll take a look.

    • @jewishbanana7055
      @jewishbanana7055 Месяц назад

      Binary is harder than you think, learn how to use microcontrollers first to get a gist of it.

    • @Anriuko
      @Anriuko 4 дня назад +1

      Good for you, and good luck developing the resilience against people telling you that you're doing this programming thing wrong. Check out Peter Cordes on Stack Overflow. If you're going to learn Assembly you'll likely bump into him sooner or later - the guy is a goldmine.

    • @Dev_with_Sel
      @Dev_with_Sel 4 дня назад

      @@Anriuko ahahaha great advice. I was already working on an Assembly project, learning more stuff every day. I'll take a look at Peter Cordes too. Thx

  • @mr.shredder5430
    @mr.shredder5430 Месяц назад

    great video prrsentation

  • @NormTurtle
    @NormTurtle Месяц назад +2

    1:45 can u please tell how u mare that animation?
    Is that blender?
    Can u share ur video creation workflow

  • @nobodyspecial1553
    @nobodyspecial1553 23 часа назад

    I like my language as simple as possible. C is perfect for me.
    And memory errors are not an issue for me with sanitizers. Add a shadow stack to really top it off.
    When I write C, I know exactly how my code will translate to machine code. In every other language, except maybe Zig, it seems more like I'm making requests than commands.

  • @thedrunknmunky6571
    @thedrunknmunky6571 Месяц назад +7

    I do enjoy programming in Haskell and Python too.

  • @science_trip
    @science_trip 7 дней назад

    just this ❤

  • @alexdefoc6919
    @alexdefoc6919 Месяц назад +3

    This is why i left using game engines, i get satisfaction creating.

  • @leonardomangano6861
    @leonardomangano6861 11 дней назад

    I feel the same

  • @iogilarb
    @iogilarb 9 дней назад +3

    why i love C? idk, i just love it

  • @hansdampf2284
    @hansdampf2284 12 дней назад

    I program rust at work and unlike it, but you’re right, there is something that feels great when programming in C. I feel like a genius programming with it and if I find a very elegant way to do something I feel like I invented this. (Although being realistic probably everything I will ever code has been invented before by someone else)

  • @timwmillard
    @timwmillard 10 дней назад +2

    So true. Love this video. I feel the exact same way with C.

  • @yotu9670
    @yotu9670 9 дней назад

    Thanks. Are you going to do a tutors about hot to use pointers skillfully as well??
    And if you want to get more subscribers (don’t know if you want :D) you should ask people in the end to subscribe. Seems to work for all the big channels.

  • @danilafoxpro2603
    @danilafoxpro2603 Месяц назад +4

    I gravitate towards C as well, for some reason. I don't know why exactly. Part of it might be the simplicity of it, that goes through and through. Language semantics are simple, and they simply map to assembly and machine code. In turn, it's simpler to hack things in if you see a way to take a particular shortcut if 'you know what you are doing'. Other languages sometimes seem to fight me on this, where they have a certain rigidity about how things are done.
    Of course there are still annoyances. Like struggling to remember how to specify types (pointers to functions that return pointers..), having to look-up operator precedence, stock malloc not necessarily being the best choice for getting memory, header files... Some of those are potentially me still figuring things out, and some annoyances I might have not discovered yet.

    • @afjelidfjssaf
      @afjelidfjssaf 15 дней назад

      yes C is "simple" aka needing unreadable unmaintainable unsafe 200 LOC for something that could be done in another language in 50 simple lines of code.
      That's why I just use Nim. Can do anything low and high level at C speed with Python syntax and optional garbage collection

    • @danilafoxpro2603
      @danilafoxpro2603 14 дней назад

      @@afjelidfjssaf Well, I personally would look more in a direction of Zig than Nim. But thanks for the suggestion.
      I am not sure how 'unreadable, unmaintainable and unsafe' my C code is. I certainly do make small mistakes from time to time that can result in pretty interesting memory accesses (which can cause crashes). But things run pretty robust after I fix those. On the other hand I can use unions to overlay multiple structs into one, and thusly pack them continuously in memory (instead of pretty much having to scatter them on the heap). I like to play with memory layout of things and with how allocations are done. Part of that process is also designing data structures and functions in such a way where it's hard to make mistakes.
      I suppose our dichotomy can be summarized as "it can be pretty good if you are careful / I don't want a language where I need to be careful". If you would be curious to see some pretty good programs written in C, I would suggest Eskil Steenberg (RUclips channel). (To mirror your mention of Nim.)

    • @afjelidfjssaf
      @afjelidfjssaf 13 дней назад

      @@danilafoxpro2603 i agree with most of what you said but I feel like its pretty hard to consistently write more robust, safe and performant code than some other languages compiler creating safe optimized C code

    • @danilafoxpro2603
      @danilafoxpro2603 13 дней назад

      @@afjelidfjssaf Mayhaps. Might depend on the person as well. Some people might just not be interested in C, and be pretty content with the language of their choice, be it compiled or interpreted. Whatever works for whoever, I suppose. So far C seems to work for me.
      Maybe at some point an epiphany will hit me and I'd exclaim "oh what I fool I was for using C all these years!" But that hasn't happened yet. :D

    • @Logan9312
      @Logan9312 11 дней назад

      Try Go if you haven’t because to me, I really like C and go feels like writing a better C

  • @hansdampf2284
    @hansdampf2284 12 дней назад +1

    Speaking of which, do you know anything books on C for the advanced programmer? I am programming C at work, but this is mostly very basic embedded stuff. The sheer amount of requirements is what makes it hard but the programming is not.

    • @Anriuko
      @Anriuko 4 дня назад +1

      C Interfaces and Implementations: Techniques for Creating Reusable Software
      Understanding and Using C Pointers: Core Techniques for Memory Management
      Expert C Programming: Deep C Secrets
      C Programming: A Modern Approach
      Algorithms in C (Sedgewick)
      Numerical Recipes in C: The Art of Scientific Computing
      The Standard C Library (Plauger)
      The Art of Computer Programming (not C per se, but at this point you don't care)

  • @nikkiinit
    @nikkiinit 12 дней назад +1

    I love C and C++ over Python, Java, and JavaScript…🎉

  • @nevokrien95
    @nevokrien95 Месяц назад

    I also like c but the ub parts of it are very sucky.
    Zig/go seems super nice for the same simplicity reasons

  • @sherkhanthelegend7169
    @sherkhanthelegend7169 19 дней назад

    I too love c

  • @ldskmain
    @ldskmain Месяц назад

    I loved it! One more subscribe for you my friend.

  • @hawkbirdtree3660
    @hawkbirdtree3660 Месяц назад +5

    J.S. Bach was a big fan of C. Coincidence? I think not!

  • @ariseyhun2085
    @ariseyhun2085 Месяц назад +4

    I would however prefer that my mechanical watch doesn't randomly break and need to be rewound again in order to reset it, because the watchmaker thought he was skilled enough to build it without proper tools, but in fact after mass producing the watch later realised that everyones watch had a defect because of one small issue. C is great, but the number of bugs and security vulnerabilities in distributed software present due to a memory issue is way too high.

    • @tiranito2834
      @tiranito2834 Месяц назад +5

      "C is great but the big number of hobbists with skill issue is bad"
      Ah yes, the floor is made of floor.
      I'm going to go up going upward and I'm going to go down going downward.
      Also, the sky is blue.

    • @ariseyhun2085
      @ariseyhun2085 Месяц назад +1

      @@tiranito2834 ok

    • @tiranito2834
      @tiranito2834 Месяц назад

      @@ariseyhun2085 indeed

    • @mariocamspam72
      @mariocamspam72 Месяц назад

      ​@@tiranito2834ok

    • @someoneunknown6894
      @someoneunknown6894 Месяц назад +2

      There are many analyzers though, linters and other tooling which prevents these issues. And while yes, rust will always be "safer" than C, it doesn't mean that C isn't safe enough.

  • @someoneunknown6894
    @someoneunknown6894 Месяц назад +1

    Great video! I wonder what you think about Zig, which still stays at a similar abstraction later to C, and yet adds some improvements (for example defer, which I miss so much in C)

  • @andrewdunbar828
    @andrewdunbar828 Месяц назад

    I'm interested in C and I'm interested in new languages. They have different sets of shortcomings and annoyances.

  • @rx808
    @rx808 Месяц назад

    naklad it

  • @thedrunknmunky6571
    @thedrunknmunky6571 Месяц назад

    C is one of those things that will take a lifetime to really learn, it's just how it is. I believe that Zig will be replacing C eventually, but its not there yet (stability-wise, community support, documentation, etc). Not Rust or C++.

    • @not_herobrine3752
      @not_herobrine3752 Месяц назад +3

      c may surprise even experts from time to time, but it doesnt take a lifetime to get competent at it

    • @mwanikimwaniki6801
      @mwanikimwaniki6801 12 дней назад

      ​@@not_herobrine3752ikr. It's such a tiny language. You could learn everything about C in no time.

  • @MagnusNemo-xc5nx
    @MagnusNemo-xc5nx Месяц назад

    you need to try Odin

  • @cycomkid
    @cycomkid 8 дней назад

    And it gives oppertunity to create memory errors😂😂

  • @mariobroselli3642
    @mariobroselli3642 Месяц назад

    What about PHP? 😮

    • @webnplay
      @webnplay Месяц назад +1

      PHP is a dynamic language built on top of a c-compiler (PHP-C)….its a black box on top of a black box and not very good either

    • @mariobroselli3642
      @mariobroselli3642 Месяц назад

      @@webnplay and what IS very good in your opinion? Stuff Like zig Go or Rust or Haskell Clojure or Elixir?

    • @anoniemoss3566
      @anoniemoss3566 7 дней назад

      PHP is an awesome language and a great tool for server side scripting. Its not meant to do the same things as C. You would never build parts of an OS in PHP. And the only time you really want to think of using C for returning web content is in the case of an embedded device.

  • @userrrr32
    @userrrr32 24 дня назад

    Ive started programing with python as it was very easy and powerul. but then after that I wanted to learn a lower level langauge like rust or C++. ive tried rust. and c++. but they are just too much for me. the C++ and rust syntax was too complicated. you could type the same thing in a million different ways and code was just genraly hard too read. but then I ended up on C. C was perfect. C is actualy suprsingly easy compared to rsut and C++. I like it because it dosent have all the extra bs like rust and C++ but still abstracted enought that im not writing 1s and 0s. also the rust documentation is absloute shit. its like if they expect you to know it before you know it. but atleast C++ documentation is a bit better. but C has the best documentation ive ever seen. mayve if rust gets more better documentation ill use it. but C is the best in my opinion. its abstract enough where you arent programing in assembly. but its dosent abstract too much where there is too much bs and annoying syntax

    • @poleve5409
      @poleve5409 7 дней назад +1

      rust's documentation is pretty great wdym? It even has a section for general programming concepts, which is something you don't see often

  • @NormTurtle
    @NormTurtle Месяц назад

    I love how people admire C .
    But problem is that im in a data science program and they are forcing to use python .
    Hence have to left C .

  • @loganhodgsn
    @loganhodgsn Месяц назад

    Black boxes=skill issue

  • @AdventuresOfPepero
    @AdventuresOfPepero 7 дней назад

    i have the same feeling. after trying new languages, still come back to c. it's kind of my home :)

  • @ewerybody
    @ewerybody Месяц назад

    Oh Hai! Interesting video. I'm curious getting into C. Too much Python work to do tho :/
    What I like about the video:
    1:42 the black boxes analogy👍
    2:43 this transition to the blank page!👌
    What I disliked:
    0:22 this anime style character?! What the?! why? Oh this is in all your vids :/
    1:04 eeeeww D: black single use gloves! I hate it already when peeps do this in cooking videos. But a programming video? .. please!
    2:16 oh you DUCT TAPED them to your wrists? OK nevermind

  • @MrAlanCristhian
    @MrAlanCristhian Месяц назад +1

    Because you are not manipulable by hype.

  • @Qohist
    @Qohist Месяц назад +3

    just program in binary simple!

  • @Garfield_Minecraft
    @Garfield_Minecraft Месяц назад +1

    boomer