Have you ever had to use bit shifting in real projects?

后端 未结 30 3805
故里飘歌
故里飘歌 2020-12-02 05:35

Have you ever had to use bit shifting in real programming projects? Most (if not all) high level languages have shift operators in them, but when would you actually need to

30条回答
  •  旧巷少年郎
    2020-12-02 05:56

    Bit shifting doesn't solve high level programming problems, but just we sometimes have to solve lower level problems, and it's convenient to not have to write a separate library in C to do it. That's when it gets used most is my guess.

    I have personally used it in writing an encoder for an EBCDIC character set converter.

提交回复
热议问题