Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bitwise NOT Operator in D

Is there a bitwise NOT operator included in D2? If not, what's an alternative? Will ! just work? I'm guessing it won't because if it did !1 would equal true, which it doesn't.

like image 815
Jeroen Avatar asked Aug 24 '26 05:08

Jeroen


1 Answers

From the comments:

The correct way to do it is using the Complement Expression. (~1 as opposed to !1)

like image 122
Jeroen Avatar answered Aug 25 '26 22:08

Jeroen



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!