#include <iostream>
#include <algorithm>
#include <utility>
using namespace std;

const int N = 50;
const int INF = 1e9;

typedef pair<int, double> P;

int main(){
    int n;
    int dp[N + 1];
    int ps[] = {380, 550, 850};
    int ws[] = {2, 3, 5};
    P ds[] = { make_pair(5, 0.8), make_pair(4, 0.85), make_pair(3, 0.88) };
    
    while(cin >> n, n){
        fill(dp, dp + N + 1, INF);
        dp[0] = 0;
        n /= 100;
        for(int i = 0;i < n - 2;++i){
            for(int j = 0;j < 3 && i + ws[j] <= n;++j){
                dp[i + ws[j]] = min(dp[i + ws[j]], dp[i] + ps[j]);
                int idx = i + (ws[j] * ds[j].first);
                if(idx <= n){
                    dp[idx] = min(dp[idx], (int)(dp[i] + ps[j] * ds[j].second * ds[j].first));
                }
            }
        }
        cout << dp[n] << endl;
    }
    return 0;
}