Java Utililty Methods Bitwise XOR

List of utility methods to do Bitwise XOR

Description

The list of methods to do Bitwise XOR are organized into topic(s).

Method

intbitDifference(String s1, String s2)
bit Difference
int sum = 0;
for (int i = 0; i < s1.length(); i++) {
    if (s1.charAt(i) != s2.charAt(i))
        sum++;
return sum;
BytebitXor(Byte a, Byte b)
bit Xor
if (a == null || b == null) {
    if (a == null) {
        a = 0;
    if (b == null) {
        b = 0;
return (byte) (a ^ b);
longbitXor(Long a, Long b)
bit Xor
return a ^ b;