Given an integer (signed 32 bits), write a function to check whether it is a power of 4.
Input: 16 Output: true
Input: 5 Output: false
Follow up: Could you solve it without loops/recursion?
Solution: Please check the main.js snippet for the solution. If you have different approach in mind or have any suggestion for this implementation feel free to share in the comment below. Thanks!