A Tour of C's Many Operators

แชร์
ฝัง
  • เผยแพร่เมื่อ 28 ธ.ค. 2024

ความคิดเห็น • 17

  • @rafalzasada8826
    @rafalzasada8826 4 ปีที่แล้ว +21

    Although I am not complete beginner I like to watch those easy videos to refresh and possibly feel some gaps.

    • @GAMarine137
      @GAMarine137 4 หลายเดือนก่อน

      Yes, especially after a decades long break from C

  • @mburdiyan
    @mburdiyan ปีที่แล้ว +2

    As a programmer with more than a decade of experience and someone who have used bitwise operators quite a few times, I always have to lookup their meaning every time I use them. I understand what they do quite well, but then I forget it for some reason. With the way you explained them I think they now are going to stick :)

  • @mikemccartneyable
    @mikemccartneyable 4 หลายเดือนก่อน

    Perfectly explained and one of the most prolific uses of C that has been replicated in nearly every subsequent language. I wish I knew these C coding standards before I got into Arduino projects as I had to work out what was going on in reverse 🤪

  • @sahilyadav998
    @sahilyadav998 2 ปีที่แล้ว +3

    How has your channel not crossed million yet? :-( Hope it does soon. Love your videos. Keep up the great work man.

  • @messengerofiexist2139
    @messengerofiexist2139 3 ปีที่แล้ว

    Using gzip/zlib as an example:
    Why would you want to compress only the contents of a container and not the entire container?
    Why use fopen() at all? NTFS is not a good reason to use fopen().
    Why not rb from disk when you know, or can determine, which sectors contain the file?
    Wouldn’t gzipping everything be preferable to gzipping only the contents of a file?

  • @Terms-and-Conditions
    @Terms-and-Conditions 2 ปีที่แล้ว

    everything was so nice and then its like we entered hell when he started talking about bitwise operators

  • @SekharPariga
    @SekharPariga 6 ปีที่แล้ว +3

    Simple n Nice 👍 Video

  • @cipherxen2
    @cipherxen2 3 ปีที่แล้ว

    You've to consider 2's complement while getting result of ~ operator (if the number is signed)

  • @LilacSneakyOwl
    @LilacSneakyOwl 5 ปีที่แล้ว

    Hello! I was wondering if C had operator overload?
    Say I have a struct (matrix for example) and I wanna add two matrices together, is there a way to overload + so that I can add matrices instead of only integers?

    • @JacobSorber
      @JacobSorber  5 ปีที่แล้ว +1

      Sorry. C doesn't support operator overloading. It would be fun if it did.

    • @LilacSneakyOwl
      @LilacSneakyOwl 5 ปีที่แล้ว

      @@JacobSorber it'd be so fun...
      Anyways, great vid ! Short and clear as always. Loving it !

    • @alainterieur5004
      @alainterieur5004 4 ปีที่แล้ว

      @@LilacSneakyOwl ( just learn cpp to do that )

  • @astralchan
    @astralchan 3 ปีที่แล้ว

    sizeof operator?

  • @swarnavasamanta2628
    @swarnavasamanta2628 3 ปีที่แล้ว

    I have a minor confusion. Some say that in evaluation of expression is from right to left, is that correct ? So like in y=x++; shouldn't the compiler just do x++(x remaining unchanged at this point) and then when x is assigned to y shouldn't the new value be stored in y as y = x references x once more ?

  • @simonmaracine4721
    @simonmaracine4721 4 ปีที่แล้ว

    1:32 You don't write code like this in the first place! It's just stupid and confusing.

    • @ahmadhadwan
      @ahmadhadwan 3 ปีที่แล้ว +3

      not really there are some cases where you want to increment a variable and pass it to a function call at the same time, so its good to know the precedence of both operators