Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Linq;
- namespace Round_Away_From_Zero
- {
- class Program
- {
- static void Main(string[] args)
- {
- double[] arr = Console.ReadLine().Split().Select(double.Parse).ToArray();
- for (int i = 0; i < arr.Length; i++)
- {
- Console.Write(arr[i] + " => ");
- Console.Write(Math.Round(arr[i], MidpointRounding.AwayFromZero));
- Console.WriteLine();
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement