Given a positive integernum, write a function which returns True ifnumis a perfect square else False.
Note:Do notuse any built-in library function such assqrt.
Example 1: Input: 16 Returns: True
Example 2: Input: 14 Returns: False
除了1 以外, 所以数的平方跟都小于等于这个数的二分之一, 二分查找法