static void Main(String[] args)
    {
        MedianFinder MF = new MedianFinder();

        int T = int.Parse(Console.ReadLine());

        while (T-- > 0)
        {
            MF.Add(int.Parse(Console.ReadLine()));
            Console.WriteLine("{0:F1}", MF.GetMedian());
        }
    }