#include <iostream>
#include <vector>

using namespace std;

int main() {
	int n; cin >> n;
	vector<long long> a(n);
	for (long long& e : a) cin >> e;
	long long ans = 1000;
	for (int i = 1; i < n; ++i)
		if (a[i - 1] < a[i])
			ans = ans - ans / a[i - 1] * a[i - 1] + ans / a[i - 1] * a[i];
	cout << ans << endl;

	return 0;
}