#include <bits/stdc++.h>
using namespace std;
int main()
{
int a,b,c,d,e;
while(cin>>a>>b>>c)
if((a>=10)&&(c>=2)){
d=a/10+b;
e=c/2+b;
if(d>e)
cout<<a<<" 個餅乾,"<<e<<" 盒巧克力,"<<c<<" 個蛋糕。"<<endl;
else
cout<<a<<" 個餅乾,"<<d<<" 盒巧克力,"<<c<<" 個蛋糕。"<<endl;}
else
cout<<a<<" 個餅乾,"<<b<<" 盒巧克力,"<<c<<" 個蛋糕。"<<endl;
return 0;
}