#include<stdio.h>



int main(void){
	
	int a,b,c,i,j,k,sobako,kingaku[850]={0},sum,temp,count;
	int ahiki,a_amari,bhiki,b_amari,chiki,c_amari;
	int a_weight,b_weight,c_weight;
	
	while(1){
		
		count=0;
		sobako=0;
		a=380; //200g 5Ü20%ø«
		b=550; //300g 4Ü15%ø«
		c=850; //500g 3Ü12%ø«
		a_weight=200;	//êÜÌd³
		b_weight=300;
		c_weight=500;
		
		for(i=0;i<850;i++){
			kingaku[i]=0;
		}
		
		scanf("%d",&sobako);
		
		if(sobako==0){
			break;
		}

		for(i=0;i<50;i++){
			for(j=0;j<40;j++){
				for(k=0;k<30;k++){
					sum=a_weight*i+b_weight*j+c_weight*k;
					if(sum==sobako){
						
						ahiki=i/5;	//øªKp³êéÜÌÂ
						a_amari=i%5; //øKpOÌÜÌÂ
						
						bhiki=j/4;
						b_amari=j%4;
						
						chiki=k/3;
						c_amari=k%3;
						
						kingaku[count]=(5*ahiki*0.80+a_amari)*a+(4*bhiki*0.85+b_amari)*b+(3*chiki*0.88+c_amari)*c;
						
						count++;			
					}
				}
			}
		}

		/*for(i=0;i<count;i++){
			printf("kingaku[%d]=%d\n",i,kingaku[i]);
		}*/
		
		for(i=0;i<count-1;i++){
			for(j=(count-1);j>i;j--){
				if(kingaku[j-1]>kingaku[j] && kingaku[j]!=0 && kingaku[j-1]!=0){
					temp=kingaku[j-1];
					kingaku[j-1]=kingaku[j];
					kingaku[j]=temp;
					//printf("kingaku[%d]==%d\n",j,kingaku[j]);
				}
			}
		}
		
		/*for(i=0;i<count;i++){
			printf("kingaku[%d]=%d\n",i,kingaku[i]);
		}*/
			printf("%d",kingaku[0]);
	}
	return 0;
}