Top "Bit-manipulation" questions

The manipulation of individual bits.

Android In App Billing: securing application public key

From Android In App Billing version 3 (TrivialDrive)sample application coming with sdk MainActivity.java /* base64EncodedPublicKey should be YOUR APPLICATION'S …

android security bit-manipulation in-app-billing public-key
How can I use bit shifting to replace integer division?

I understand how to do it for powers of 2 so that's not my question. For example, if I want to …

c++ bit-manipulation integer-division
How do I represent and work with n-bit vectors in Python?

In an assignment I am currently working on we need to work with bit vectors, but I am very unsure …

python bit-manipulation bitarray bitvector
Bit Setting and Bit Shifting in Ansi C

Can anyone explain this bitwise operation syntax? #define Bitset(var,bitno) ((var) |=1UL<<(bitno)) I know it sets …

c bit-manipulation bitwise-operators bit-shift ansi
Find number of bits to be flipped to get maximum 1's in array

We have a bit array like below {1 0 1 0 0 1 0 1} Number of bits in above array is 8 If we take range from [1,5] then …

algorithm bit-manipulation dynamic-programming
Implementing logical negation with only bitwise operators (except !)

~ & ^ | + << >> are the only operations I can use Before I continue, this is a homework question, …

c bit-manipulation boolean-logic negation
How to check if a particular bit is set in C#

In C#, I have a 32 bit value which I am storing in an int. I need to see if a …

c# bit-manipulation bit
Bitwise overflow checking in c

I am trying to write two functions that will check/prevent overflow in c (using only ! ~ | & ^ +) but cant get …

c overflow bit-manipulation operations
What is the meaning of double tilde (~~) in Java?

When browsing the source code of Guava, I came across the following piece of code (part of the implementation of …

java gwt bit-manipulation bitwise-operators
Change XOR to XNOR

I am working with a XNOR encrypted file whose key is not known. I want to modify the xortool which …

python bit-manipulation bitwise-operators xor bitwise-xor