#include <bits/stdc++.h>
int main() {
  int n, a, b, d, i;
  int V[10000] = {0};
  double tmp, prev;
  char S[10000];
  scanf("%d", &n);
  tmp = 0.0;
  for (i = 0; i < n; i++) {
    scanf("%d", &V[i]);
  }
  prev = (double)V[n - 1];
  for (i = n - 2; i >= 0; i--) {
    prev = (double)(prev + V[i]) / 2;
  }
  printf("%.10lf\n", (double)prev);
  return 0;
}
