PP1. Week 8. Functions

Function tabulation

Write a program that prints the values of a function y = 3 · sin(x) on segment from a to b inclusively with step h.


Three double values a, b and h are given in one line.


Print in each line two numbers x and y, ascending x with three decimal digits.

Time limit 1 second
Memory limit 128 MiB
Input example #1
1 2 0.5
Output example #1
1.000 2.524
1.500 2.992
2.000 2.728