


'''simple docstring'''







import os
from string import ascii_letters

lowercase__     :  Optional[int]    					=			ascii_letters + ' \t\n'





def 						snake_case__ ():
    UpperCamelCase__      =			os.path.split(os.path.realpath(lowerCAmelCase_	)	)
    UpperCamelCase__      =			{}
    with open(path[0] + "/dictionary.txt"	) as dictionary_file:
        for word in dictionary_file.read().split("\n"	):
            UpperCamelCase__      =			None
    return english_words


lowercase__     :  Dict    					=			load_dictionary()





def 						snake_case__ (lowerCAmelCase_	):
    UpperCamelCase__      =			message.upper()
    UpperCamelCase__      =			remove_non_letters(lowerCAmelCase_	)
    UpperCamelCase__      =			message.split()
    UpperCamelCase__      =			len([word for word in possible_words if word in ENGLISH_WORDS]	)
    return float(lowerCAmelCase_	) / len(lowerCAmelCase_	)





def 						snake_case__ (lowerCAmelCase_	):
    return "".join(symbol for symbol in message if symbol in LETTERS_AND_SPACE	)





def 						snake_case__ (lowerCAmelCase_					,  lowerCAmelCase_ = 20					,  lowerCAmelCase_ = 85	):
    UpperCamelCase__      =			get_english_count(lowerCAmelCase_	) * 1_00 >= word_percentage
    UpperCamelCase__      =			len(remove_non_letters(lowerCAmelCase_	)	)
    UpperCamelCase__      =			(float(lowerCAmelCase_	) / len(lowerCAmelCase_	)) * 1_00
    UpperCamelCase__      =			message_letters_percentage >= letter_percentage
    return words_match and letters_match


if __name__ == "__main__":
      import doctest

      doctest.testmod()









'''simple docstring'''







from math import radians as angle_to_radians
from math import sin

# Acceleration Constant on Earth (unit m/s^2)
lowercase__     :  str    					=			9.8_0_6_6_5





def 						snake_case__ (lowerCAmelCase_					,  lowerCAmelCase_	):

    # Ensure valid instance
    if not isinstance(lowerCAmelCase_					,  (int, float)	):
        raise TypeError("Invalid velocity. Should be a positive number."	)

    if not isinstance(lowerCAmelCase_					,  (int, float)	):
        raise TypeError("Invalid angle. Range is 1-90 degrees."	)

    # Ensure valid angle
    if angle > 90 or angle < 1:
        raise ValueError("Invalid angle. Range is 1-90 degrees."	)

    # Ensure valid velocity
    if init_velocity < 0:
        raise ValueError("Invalid velocity. Should be a positive number."	)





def 						snake_case__ (lowerCAmelCase_					,  lowerCAmelCase_	):
    check_args(lowerCAmelCase_					,  lowerCAmelCase_	)
    UpperCamelCase__      =			angle_to_radians(2 * angle	)
    return round(init_velocity**2 * sin(lowerCAmelCase_	) / g					,  2	)





def 						snake_case__ (lowerCAmelCase_					,  lowerCAmelCase_	):
    check_args(lowerCAmelCase_					,  lowerCAmelCase_	)
    UpperCamelCase__      =			angle_to_radians(lowerCAmelCase_	)
    return round(init_velocity**2 * sin(lowerCAmelCase_	) ** 2 / (2 * g)					,  2	)





def 						snake_case__ (lowerCAmelCase_					,  lowerCAmelCase_	):
    check_args(lowerCAmelCase_					,  lowerCAmelCase_	)
    UpperCamelCase__      =			angle_to_radians(lowerCAmelCase_	)
    return round(2 * init_velocity * sin(lowerCAmelCase_	) / g					,  2	)





def 						snake_case__ ():
    UpperCamelCase__    ,  UpperCamelCase__      =			25, 20
    assert horizontal_distance(lowerCAmelCase_					,  lowerCAmelCase_	) == 40.97
    assert max_height(lowerCAmelCase_					,  lowerCAmelCase_	) == 3.73
    assert total_time(lowerCAmelCase_					,  lowerCAmelCase_	) == 1.74


if __name__ == "__main__":
      from doctest import testmod

      testmod()

      # Get input from user
      lowercase__     :  Union[str, Any]    					=			float(input('Initial Velocity: ').strip())

      # Get input from user
      lowercase__     :  Any    					=			float(input('angle: ').strip())

      # Print results
      print()
      print('Results: ')
      print(F'''Horizontal Distance: {horizontal_distance(init_vel, angle)!s} [m]''')
      print(F'''Maximum Height: {max_height(init_vel, angle)!s} [m]''')
      print(F'''Total Time: {total_time(init_vel, angle)!s} [s]''')




