#include <iostream>
#include <vector>
#include <cmath>
using namespace std;

constexpr int INF = 1e9;

int main() {
    vector<int> w = {2, 3, 5}, v = {380, 550, 850};
    vector<int> dis = {20, 15, 12}, dis_cnt = {5, 4, 3};
    vector<vector<int>> dp(4, vector<int>(51, INF));
    dp[0][0] = 0;
    for(int i=0; i<3; ++i) {
        for(int j=50; j>=0; --j) {
            dp[i+1][j] = min(dp[i+1][j], dp[i][j]);
            for(int k=1; k<=(50-j+w[i]-1)/w[i]; ++k) {
                int next = min(50, j+w[i]*k);
                dp[i+1][next] = min(dp[i+1][next], dp[i][j]+(v[i]*dis_cnt[i])*(k/dis_cnt[i])*(100-dis[i])/100+v[i]*(k%dis_cnt[i]));
            }
        }
    }
    int n;
    while(cin >> n, n) {
        n /= 100;
        cout << dp[3][n] << endl;
    }
}
