Bitwise Operators | Solidity 0.8

แชร์
ฝัง
  • เผยแพร่เมื่อ 9 ก.พ. 2025

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

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

    0:10 - and
    1:30 - or
    2:49 - xor
    4:27 - not
    5:28 - shift left
    6:53 - shift right
    8:13 - Remix demo
    10:05 - Code challenge - get last N bits
    13:33 - Get last N bits using mod
    Code
    solidity-by-example.org/bitwise/
    Take a course
    www.smartcontract.engineer/

  • @Ahmad_Faraz_web3Dev
    @Ahmad_Faraz_web3Dev ปีที่แล้ว

    Simple ,to the point and amazing content.

  • @LincolnAbraham-br3gk
    @LincolnAbraham-br3gk 6 หลายเดือนก่อน

    It's so clear, thanks!

  • @meka4996
    @meka4996 ปีที่แล้ว

    You are on fire!

  • @amey9719
    @amey9719 2 ปีที่แล้ว

    Thank you so much for these videos ❤

  • @bhok5228
    @bhok5228 2 ปีที่แล้ว

    Thanks for this top content

  • @adityabhattad4614
    @adityabhattad4614 2 ปีที่แล้ว

    Just know that you are awesome!

  • @Ts2pc
    @Ts2pc 2 ปีที่แล้ว

    Interesting, It is totally new for me. Thanks a lot!

  • @alex-dk2rj
    @alex-dk2rj 2 ปีที่แล้ว +2

    8:32 think you meant to type 11 😬

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

    Very interesting indeed. Now, a newbie question: I have studied quite a few contracts and I cannot figure where these operations may be needed. Any example, please?

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

      github.com/Uniswap/v3-core/blob/main/contracts/libraries/TickBitmap.sol

    • @aboutikareda1565
      @aboutikareda1565 ปีที่แล้ว

      ​@@smartcontractprogrammer or to solve Gatekeeper One from Ethernaut 😃Thank you for your videos.

  • @zacharysnyder3905
    @zacharysnyder3905 2 ปีที่แล้ว

    Can you please give me an update on IERC20 please? I made a code that uses IERC20, but I put everything in correctly. I made the IERC20 code. And I have imported it in, and have used it in my code, but it is underlined red? I just don’t get why that is happening.

    • @alex-dk2rj
      @alex-dk2rj 2 ปีที่แล้ว

      What’s the error

    • @zacharysnyder3905
      @zacharysnyder3905 2 ปีที่แล้ว

      @@alex-dk2rj It’s just underlining the IERC20 red. But, I don’t get what the error is. So, I am just going to put the things in the code to fix it.

    • @alex-dk2rj
      @alex-dk2rj 2 ปีที่แล้ว

      @@zacharysnyder3905 should give you some error if you hover? did you implement all the methods and the function signatures match? Or is the error from sollint?

    • @zacharysnyder3905
      @zacharysnyder3905 2 ปีที่แล้ว

      @@alex-dk2rj I don’t think so, but I have just deleted the IERC20 code. Now, I have just turned it into events that have indexed variables in them. Here is a sharing for what I mean:
      contract ________ {
      event Deposit (address indexed sender, uint amount);
      event Submit (address indexed txId);
      event Approve (address indexed owner, uint indexed txId);
      event Revoke (address indexed owner, uint indexed txId);
      event Execute (uint indexed txId);
      }
      Do you see where I am going with this? I think it will just be less complicated for me, so I don’t have to do a lot more work.

    • @alex-dk2rj
      @alex-dk2rj 2 ปีที่แล้ว

      @@zacharysnyder3905 not exactly sure what you’re trying to do but did you import the IERC20 interface properly?

  • @vishalkulkarni3977
    @vishalkulkarni3977 2 ปีที่แล้ว

    thank you
    can you make video on banchor v2 protocol which reduces the impermanent loss

    • @smartcontractprogrammer
      @smartcontractprogrammer  2 ปีที่แล้ว

      no, I heard they temporary stopped their impermanent loss protection