diff --git a/algorithms/python/ValidPerfectSquare/ValidPerfectSquare.py b/algorithms/python/ValidPerfectSquare/ValidPerfectSquare.py new file mode 100644 index 00000000..11da9539 --- /dev/null +++ b/algorithms/python/ValidPerfectSquare/ValidPerfectSquare.py @@ -0,0 +1,3 @@ +class Solution: + def isPerfectSquare(self, num: int) -> bool: + return int(sqrt(num))**2==num \ No newline at end of file