Binary Logical Shifts

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

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

  • @ronniesaieed1373
    @ronniesaieed1373 5 лет назад +10

    Thank you so much! I have an exam tomorrow and i was afraid i might never understand that.

  • @varalakshmibogale5291
    @varalakshmibogale5291 3 года назад +2

    There is a question which says
    State one effect this logical shift has on the binary value.
    Please answer this as I don’t get it

    • @greenishtri
      @greenishtri 3 года назад +1

      We might lose our data if we depend on logical shifter

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

    im slightly confused when you said the right logical shift is MOD division. isn't is DIV division as its returning the whole number and not the remainder e.g 15 DIV 2 would return 7

    • @MrBrownCS
      @MrBrownCS  6 лет назад +3

      Yeah, if I said that mistakenly I apologise

    • @Kooner14
      @Kooner14 4 года назад +1

      @@MrBrownCS would the last one not produce an overflow error?

  • @dejukeysa5200
    @dejukeysa5200 6 лет назад +11

    the tutor was nise but I'm not clear because of your speed

    • @WhoisFaieq
      @WhoisFaieq 4 месяца назад

      because ur African black man you dumb

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

    I'm a bit confused, is the steps really important for the binary shift at the end or do you get marks for writing the steps for example in this case writing the steps for three? (this question is for the question at the end of the video)

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

      Best to do each step, especially if there are working marks (i.e. it's not a 1 marker)

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

    you are very good sir thank you

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

    Isn't right shift multiply, and left shift divide, so I don't get what u said

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

      right shift divide and left shift multiply. Although don't think it will be useful after ~ 730 days 😁

    • @overlord3481
      @overlord3481 3 года назад +1

      @@arnoahmed9269 too late lol

  • @princeakilesh4881
    @princeakilesh4881 3 года назад +2

    Hello sir,
    Can you do a proper playlist for Computer Science P3 summarised theory videos ?

  • @abdulraafey737
    @abdulraafey737 Год назад

    Does the overflow error also occur in right logical shift? or is it just for the left one?

    • @iblondse
      @iblondse Год назад

      Only for increase (left) I think. In a right logical shift it just wouldn't make any sense

  • @Tempri
    @Tempri 6 лет назад

    What would be the reason for doing this? Just as a way of multiplying and dividing or does it go further than that?

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

      They can be used to round I believe, but I've only ever used a right shift in programming for division, just because often algorithms work by dividing things (arrays, memory, GPU threads etc) by 2, and this is a super efficient way to do it - they are so trivial for a computer to do

    • @Tempri
      @Tempri 6 лет назад

      Computer Science Tutor ah okay, thank youu

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

      @@MrBrownCS For rounding I would just use a bitwise AND, with zeroes up to the LSB for rounding, then ones the rest of the way.

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

    So if you do a binary shift by 2 you are doing it by 8?

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

      A ''binary shift of 2" means you are either dividing by 4 or multiplying by 4 depending on the direction of the shift. It's 2 to the power x (2^x) where x is how many shifts you are doing

    • @elizas1921
      @elizas1921 6 лет назад

      Computer Science Tutor ah thank you ❤️

  • @vivian364
    @vivian364 4 года назад +1

    Is logical shift and binary shift the same thing?

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

    Thanks brother!

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

    Hi There: Could you explain why 1101 is 13 in base 10 ? Thanks for this amazing video!

    • @n00b_asaurus
      @n00b_asaurus 4 года назад +1

      Search bar's right up there mate.

    • @seth6101
      @seth6101 4 года назад +3

      8 + 4 + 1 = 13

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

    tysm

  • @MsMrsGirly
    @MsMrsGirly 6 лет назад

    how much marks would this be worth in the exam?exam tomorrow YIKES!

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

      Probably only a couple. Good luck!

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

    lmao bestie i thought he was speaking french in the beggening

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

    Shifting bits appears here to assume a big-endian system. But the thing is, computer registers, memory addresses, and processors are LITTLE-endian!

  • @CristianoRonaldo-rq6rd
    @CristianoRonaldo-rq6rd 4 года назад

    who is 13 years old and is trying to do their homework due in 10 minutes