//Discounts of Buckwheat
#include<bits/stdc++.h>
using namespace std;
#define INF 10000

int dp[7][51]={0};
int p[6][2]={{2, 380}, {3, 550}, {5, 850}, {10, 1520}, {12, 1870}, {15, 2244}};

void print(){
  for(int i=0; i<7; i++){
    for(int j=0; j<20; j++)
      printf("%6d", dp[i][j]);
    cout<<endl;
  }
}

int main(){
  memset(dp, 0, sizeof(dp));
  for(int i=0; i<51; i++)dp[0][i]=0;

  for(int i=0; i<6; i++){
    for(int j=0; j<51; j++){
      int min_v=INF;
      for(int n=1; ; n++){
        if(j-p[i][0]*n<0)break;
        if(j-p[i][0]*n!=0 && dp[i][j-p[i][0]*n]==0)continue;
        if(min_v>dp[i][j-p[i][0]*n]+p[i][1]*n)
          min_v=dp[i][j-p[i][0]*n]+p[i][1]*n;
      }
      if(dp[i][j]!=0)min_v=min(min_v, dp[i][j]);
      else if(min_v==INF)min_v=0;
      dp[i+1][j]=min_v;
    }
  }
  //print();
  int n;
  while(true){
    cin>>n;
    if(n==0)break;
    cout<<dp[6][n/100]<<endl;
  }
  return 0;
}