Given an integer N, count the numbers having an odd number of factors from 1 to N (inclusive).
N = 5
From 1 - 5 only 2 numbers,
1 and 4 are having odd number
N = 1
1 have only 1(odd)
You don't need to read input or print anything. Your task is to complete the function count() which takes an integer N as input parameters and returns an integer, the total count of numbers from 1 to N having an odd number of factors.
Expected Time Complexity: O(sqrt(N)) Expected Space Complexity: O(1)