def is_power_of_two(n: int) -> bool:
     # A number is a power of two if it is greater than 0 and
    # there is only one bit set in its binary representation.
    # Check if n is greater than 0 and if n & (n - 1) is 0
    return n > 0 and (n & (n - 1)) == 0

# Test cases
print(is_power_of_two(1))  
print(is_power_of_two(16))  
print(is_power_of_two(3))  
print(is_power_of_two(0))  
print(is_power_of_two(-2)) 