摘要:
位运算,判断最后一位是否为一 n - 1 // 二进制最后一位1变成0,右边的0都变成1 n & n -1 //最后一位1 变成0 n & n - 1 这个方法就是在n不等于0之前,每循环一次res就加一,同时二进制的数字里面也消去一个一 int res = 0; while(n != 0) { r 阅读全文
摘要:
Serializability of a class is enabled by the class implementing the java.io.Serializable interface. Classes that do not implement this interface will 阅读全文