谁能详细解释一下BigInteger setBit和BigInteger testBit的原理啊
其实就是位运算。setbit的原理,将当前数字 or (1 << n位)testbit的原理,当前数字 and (1 << n位),结果如果是0。就是false,否则true