摘要:
问题: Write a program to find the node at which the intersection of two singly linked lists begins. For example, the following two linked lists: begin t 阅读全文
摘要:
问题: Given a non-negative integer num, repeatedly add all its digits until the result has only one digit. For example: Given num = 38, the process is l 阅读全文
摘要:
题目: Given an integer, write a function to determine if it is a power of two. 答案: 2的幂有两个特点: 1)大于0 2)二进制形式都是首位为1,其余位为0,因此n&(n-1)等于0 阅读全文