#include <bits/stdc++.h>
int main(int argc, char *argv[]) {
  int N;
  scanf("%d", &N);
  int *A = (int *)malloc(sizeof(int) * (N + 1));
  for (int i = 0; i < N; i++) {
    scanf("%d", &A[i]);
  }
  A[N] = 100;
  int money = 1000, stock = 0;
  for (int i = 0; i < N; i++) {
    if (A[i] < A[i + 1]) {
      stock = money / A[i];
      money %= A[i];
    } else {
      money += stock * A[i];
      stock = 0;
    }
  }
  printf("%d\n", money);
  return 0;
}
