摘要:
Given an integer, write a function to determine if it is a power of two.Analysis: 给出一个整数,判断是否为2的幂方。依次除以2,若某次中余数不为0,则不是二的幂方。Answer: public boolean i... 阅读全文
摘要:
Given two stringssandt, write a function to determine iftis an anagram ofs.For example,s= "anagram",t= "nagaram", return true.s= "rat",t= "car", retur... 阅读全文