Trigonometry P37760


Statement
 

pdf   zip

thehtml

Write a program that reads a sequence of angles in degrees, and prints their sine and their cosine.

Input

Input consists of a sequence of real numbers that represent angles in degrees.

Output

For each given angle, print a line with its sine and its cosine. Print all the numbers with six digits after the decimal point.

Observation

Use the procedures that your programming language already provides to compute sines and cosines.

Public test cases
  • Input

    90
    450
    60
    10.5
    

    Output

    1.000000 0.000000
    1.000000 0.000000
    0.866025 0.500000
    0.182236 0.983255
    
  • Information
    Author
    Jordi Petit
    Language
    English
    Translator
    Carlos Molina
    Original language
    Catalan
    Other languages
    Catalan
    Official solutions
    C++ Java Pascal Python
    User solutions
    C C++ Java Python Rust