def is_limited_factor_number(x):
    if x < 1:
        return False
    
    # Special case for 1: it has no prime factors
    if x == 1:
        return True
    
    # Divide x by 2, 3, and 5 until it can no longer be divided
    for factor in [2, 3, 5]:
        while x % factor == 0:
            x //= factor
            
    # If the resulting number is not 1, it has prime factors other than 2, 3, or 5
    return x == 1

# Main function to get user input
def main():
    try:
        # Prompt the user to enter a positive integer
        x = int(input("Enter a positive integer: "))
        
        # Check if the number is less than 1
        if x < 1:
            print("Output: false")  # Output false for invalid input
            return
        
        # Check if x is a limited factor number
        result = is_limited_factor_number(x)
        if result:
            # Output true and explanation for limited factor number
            print("Output: true")
            print(f"Explanation: {x} is a limited factor number since it has no prime factors other than 2, 3, or 5.")
        else:
            # Output false and explanation for not being a limited factor number
            print("Output: false")
            print(f"Explanation: {x} is not a limited factor number since it includes prime factors other than 2, 3, or 5.")
    except ValueError:
        # Handle the case where the input is not a valid integer
        print("Output: false")  # Output false for invalid input

if __name__ == "__main__":
    main()