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

const int INF = 1 << 29;

int W;

int main() {
    while (true) {
        cin >> W;
        if (W == 0) break;

        int min_cost[5000];
        fill(min_cost, min_cost+W+1, INF);
        min_cost[0] = 0;

        int g[6] = {200, 300, 500, 1000, 1200, 1500};
        int c[6] = {380, 550, 850, 1520, 1870, 2244};

        for (int j = 0; j < 6; ++j) {
            for (int k = g[j]; k <= W; ++k) {
                min_cost[k] = min(min_cost[k], min_cost[k-g[j]] + c[j]);
            }
        }

        cout << min_cost[W] << endl;
    }
    return 0;
}