Advertisement
desislava_topuzakova

02. Radians to Degrees

Apr 12th, 2020
377
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.52 KB | None | 0 0
  1. using System;
  2.  
  3. namespace _02.RadiansToDegrees
  4. {
  5.     class Program
  6.     {
  7.         static void Main(string[] args)
  8.         {
  9.             //радиани -> променлива
  10.             //градуси = радиани * 180 / пи -> променлива
  11.             //принтираме градуси с Math.Round
  12.  
  13.             double radians = double.Parse(Console.ReadLine());
  14.             double degrees = radians * 180 / Math.PI;
  15.             Console.WriteLine(Math.Round(degrees));
  16.  
  17.         }
  18.     }
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement