using System; using System.Linq; class Program { static void Main(string[] args) { string cnt = Console.ReadLine(); string str = Console.ReadLine(); string[] before = str.Split(' '); int[] after = before.Select(s => int.Parse(s)).ToArray(); int center = 0; double output = 0; Array.Sort(after); if (after.Length % 2 != 0) { center = after.Length / 2; output = after[center]; } else { center = after.Length / 2 - 1; output = (after[center] + after[center + 1]) / 2.0; } Console.WriteLine(output); Console.ReadLine(); } }