import java.util.Arrays;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int[] v = new int[n];
		for (int i = 0; i < n; i++) {
			v[i] = scanner.nextInt();
		}
		Arrays.parallelSort(v);
		long sum = 0;
		for (int i = n - 1; i > 1; i--) {
			sum += v[i];
			sum <<= 1;
		}
		sum += v[0] + v[1];
		System.out.println((double) sum / (1l << (n - 1)));

	}
} import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int[] v = new int[n];
		for (int i = 0; i < n; i++) {
			v[i] = scanner.nextInt();
		}
		Arrays.parallelSort(v);
		long sum = 0;
		for (int i = n - 1; i > 1; i--) {
			sum += v[i];
			sum <<= 1;
		}
		sum += v[0] + v[1];
		System.out.println((double) sum / (1l << (n - 1)));

	}
} Main public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int[] v = new int[n];
		for (int i = 0; i < n; i++) {
			v[i] = scanner.nextInt();
		}
		Arrays.parallelSort(v);
		long sum = 0;
		for (int i = n - 1; i > 1; i--) {
			sum += v[i];
			sum <<= 1;
		}
		sum += v[0] + v[1];
		System.out.println((double) sum / (1l << (n - 1)));

	} main {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int[] v = new int[n];
		for (int i = 0; i < n; i++) {
			v[i] = scanner.nextInt();
		}
		Arrays.parallelSort(v);
		long sum = 0;
		for (int i = n - 1; i > 1; i--) {
			sum += v[i];
			sum <<= 1;
		}
		sum += v[0] + v[1];
		System.out.println((double) sum / (1l << (n - 1)));

	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int n = scanner.nextInt(); n scanner.nextInt() scanner.nextInt scanner int[] v = new int[n]; v new int[n] n for (int i = 0; i < n; i++) {
			v[i] = scanner.nextInt();
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			v[i] = scanner.nextInt();
		} {
			v[i] = scanner.nextInt();
		} v[i] = scanner.nextInt() v[i] v i scanner.nextInt() scanner.nextInt scanner Arrays.parallelSort(v) Arrays.parallelSort Arrays v long sum = 0; sum 0 for (int i = n - 1; i > 1; i--) {
			sum += v[i];
			sum <<= 1;
		} int i = n - 1; int i = n - 1; i n - 1 n 1 i > 1 i 1 i-- i-- i {
			sum += v[i];
			sum <<= 1;
		} {
			sum += v[i];
			sum <<= 1;
		} sum += v[i] sum v[i] v i sum <<= 1 sum 1 sum += v[0] + v[1] sum v[0] + v[1] v[0] v 0 v[1] v 1 System.out.println((double) sum / (1l << (n - 1))) System.out.println System.out System System.out (double) sum / (1l << (n - 1)) (double) sum (1l << (n - 1)) 1l (n - 1) n 1 String[] args args public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int[] v = new int[n];
		for (int i = 0; i < n; i++) {
			v[i] = scanner.nextInt();
		}
		Arrays.parallelSort(v);
		long sum = 0;
		for (int i = n - 1; i > 1; i--) {
			sum += v[i];
			sum <<= 1;
		}
		sum += v[0] + v[1];
		System.out.println((double) sum / (1l << (n - 1)));

	}
} public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int[] v = new int[n];
		for (int i = 0; i < n; i++) {
			v[i] = scanner.nextInt();
		}
		Arrays.parallelSort(v);
		long sum = 0;
		for (int i = n - 1; i > 1; i--) {
			sum += v[i];
			sum <<= 1;
		}
		sum += v[0] + v[1];
		System.out.println((double) sum / (1l << (n - 1)));

	}
} Main
import java.util.Arrays;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int n = scanner.nextInt();
		int[] v = new int[n];
		for (int i = 0; i < n; i++) {
			v[i] = scanner.nextInt();
		}
		Arrays.parallelSort(v);
		long sum = 0;
		for (int i = n - 1; i > 1; i--) {
			sum += v[i];
			sum <<= 1;
		}
		sum += v[0] + v[1];
		System.out.println((double) sum / (1l << (n - 1)));

	}
}