摘要:
Given an integer (signed 32 bits), write a function to check whether it is a power of 4. Example 1: Input: 16 Output: true Example 2: Input: 5 Output: 阅读全文
posted @ 2018-10-04 11:30
bernieloveslife
阅读(91)
评论(0)
推荐(0)
摘要:
Given an integer, write a function to determine if it is a power of three. Example 1: Input: 27 Output: true Example 2: Input: 0 Output: false Example 阅读全文
posted @ 2018-10-04 11:30
bernieloveslife
阅读(123)
评论(0)
推荐(0)
摘要:
Given a positive integer num, write a function which returns True if num is a perfect square else False. Note: Do not use any built in library functio 阅读全文
posted @ 2018-10-04 11:29
bernieloveslife
阅读(137)
评论(0)
推荐(0)
摘要:
Find the nth digit of the infinite integer sequence 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, ... Note: n is positive and will fit within the range of a 32 b 阅读全文
posted @ 2018-10-04 11:29
bernieloveslife
阅读(98)
评论(0)
推荐(0)
摘要:
Write a program to check whether a given number is an ugly number. Ugly numbers are positive numbers whose prime factors only include 2, 3, 5. Example 阅读全文
posted @ 2018-10-04 11:29
bernieloveslife
阅读(79)
评论(0)
推荐(0)

浙公网安备 33010602011771号