#include <iostream>
#include <vector>
#include <algorithm>
#include <queue>

using namespace std;

struct data {
	int w, price;

	data() { this -> w = this -> price = 0; }
	data(int w, int price) : w(w), price(price) {}
};

bool operator<(const data &a, const data &b) {
	return a.price > b.price;
}

data operator+(const data &a, const data &b) {
	data ret;

	ret.w = a.w + b.w;
	ret.price = a.price + b.price;

	return ret;
}

int main() {
	vector<data> v;

	v.push_back( data(2, 380) );
	v.push_back( data(3, 550) );
	v.push_back( data(5, 850) );

	v.push_back( data(2*5, 380*5*(100-20)/100) );
	v.push_back( data(3*4, 550*4*(100-15)/100) );
	v.push_back( data(5*3, 850*3*(100-12)/100) );

	int price[51]; fill(&price[0], &price[0]+51, -1);

	priority_queue<data> Q; Q.push( data(0, 0) );
	while ( !Q.empty() ) {
		data d = Q.top(); Q.pop();

		if (d.w > 50 || price[d.w] >= 0) continue;
		price[d.w] = d.price;

		for (int i = 0; i < v.size(); ++i)
			Q.push( d + v[i] );
	}

	int w;
	while (cin >> w, w)
		cout << price[w/100] << endl;
}