#include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <cmath>
#include <cstdio>
#include <functional>
#include <numeric>
#include <stack>
#include <queue>
#include <map>
#include <set>
#include <utility>
#include <sstream>
#include <complex>

using namespace std;

#define FOR(i,a,b) for(long long i=(a);i<(b);i++)
#define REP(i,N) for(long long i=0;i<(N);i++)
#define ALL(s) (s).begin(),(s).end()
#define fi first
#define se second

#define PI acos(-1.0)
#define INF 1000000007

typedef long long ll;
typedef pair<ll, ll> P;
typedef pair<string, ll> PS;
typedef vector<ll> V;

double g, cost;

/*void solve(int a, int b, int c, int j, int mincost){
	if (j > g)return;
	if (a % 5 == 0 && a)mincost *= 0.8;
	if (b % 4 == 0 && b)mincost *= 0.85;
	if (c % 3 == 0 && c)mincost *= 0.88;
	if (j == g){
		cost = min(cost, mincost);
		return;
	}
	cout << mincost << endl;
	solve(a + 1, b, c, j + 200, mincost + 380);
	solve(a, b + 1, c, j + 300, mincost + 550);
	solve(a, b, c + 1, j + 500, mincost + 850);
}*/

int main(){
	while (cin >> g&&g){
		cost = INF;
		int co1 = 0, co2 = 0, co3 = 0;
		for (int i = 0; i <= 5000; i += 200){
			co1 = i / 200;
			for (int j = 0; i+j <= 5000; j += 300){
				co2 = j / 300;
				for (int k = 0; i + j + k <= 5000; k += 500){
					co3 = k / 500;
					if (i + j + k == g){
						cost = min(cost, 380*(co1-co1%5)*0.8+380*(co1%5)
							+550*(co2-co2%4)*0.85+550*(co2%4)
							+850*(co3-co3%3)*0.88+850*(co3%3));
					}
				}
			}
		}
		cout << cost << endl;
	}
}