# import sys
# input = sys.stdin.readline

def main():
    # input
    n = int(input())
    v = list(map(int, input().split()))
    v.sort()
    ans = 0
    for num, i in enumerate(v):
        if num<2:
            ans += i/2**(n-1)
        else:
            ans += i/2**(n-num)
        print(num, i, ans)


    # calc
    print(ans)


if __name__ == '__main__':
    main()
