[ZJ]b676: 63萬勞工苦輪班不像人像機器
題目:
http://zerojudge.tw/ShowProblem?problemid=b676
================================================================
#include<cstdio>
int main(void)
{
int n;
while(scanf("%d",&n)!=EOF)
{
if(n % 5 == 0)
printf("U\n");
else if(n % 5 == 1)
printf("G\n");
else if(n % 5 == 2)
printf("Y\n");
else if(n % 5 == 3)
printf("T\n");
else
printf("I\n");
}
return 0;
}
http://zerojudge.tw/ShowProblem?problemid=b676
================================================================
#include<cstdio>
int main(void)
{
int n;
while(scanf("%d",&n)!=EOF)
{
if(n % 5 == 0)
printf("U\n");
else if(n % 5 == 1)
printf("G\n");
else if(n % 5 == 2)
printf("Y\n");
else if(n % 5 == 3)
printf("T\n");
else
printf("I\n");
}
return 0;
}
留言
張貼留言