Logical Operators in C

前端 未结 8 2036
说谎
说谎 2020-11-27 08:25

I am having trouble trying to understand how logical operators work in C. I already understand how the bit-level operators work, and I also know that logical operators treat

8条回答
  •  再見小時候
    2020-11-27 09:10

    As you said the logical operators treat nonzero arguments as representing

     (0x65 && 0x55) is equal as (0x65 > 0) && (0x55 > 0)
    
     0x65 > 0 get true and 0x55 > 0 get true as well
    
     So (0x65 && 0x55)  is equal true && true = 1
    

提交回复
热议问题