#include <cstdio>
#include <cstdlib>
#include <iostream>
#include <algorithm>
#include <cstring>
using namespace std;
char mp[20][10]={"ling","yi","er","san","si","wu","liu","qi","ba","jiu"};
char mp2[20][10]={"xxx","Shi","Bai","Qian"};
char mp3[20][10]={"xxx","Wan","Yi"};
int main()
{
// freopen("in.txt","r",stdin);
int len;
char str[20];
gets(str);
len=strlen(str);
if(len==1&&str[0]=='0')//特判0
{
printf("ling");
return 0;
}
int left=0,right=len-1;
if(str[0]=='-')
{
printf("Fu");
left=1;
}
while(right-left>=4)
right-=4;
while(left<len)//每一节(4个为一节)
{
bool flag0 = 0;//记录有无积累的0
bool flagp = 0;//记录有无打印东西
while(left<=right)//每一节里的每一位(4个为一节)
{
if(str[left]=='0')
{
flag0=1;
}
else
{
if(flag0==1)//释放积累的0
{
printf(" ling");
flag0=0;
}
if(left!=0)//格式
printf(" ");
printf("%s",mp[str[left]-'0']);
flagp=1;//有东西打印了
if(left!=right)
{
printf(" %s",mp2[right-left]);
}
}
left++;
}
if(flagp==1 && right!=len-1)//打印万和亿。前提是有上面一节里有打印过东西,即若上一节全是0,则不用打印万和亿
{
printf(" %s", mp3[(len-1-right)/4] );
}
right+=4;//下一节
}
return 0;
}