Create 1372.cpp

pull/22/head
Kirigaya Kazuto 2016-07-06 10:15:29 +08:00 committed by GitHub
parent 0713bc5744
commit 654dfd1c05
1 changed files with 14 additions and 0 deletions

14
QUSTOJ/1372.cpp Normal file
View File

@ -0,0 +1,14 @@
#include <cstdio>
int main()
{
int n;
scanf("%d",&n);
int f=0;
int m=3;
for(int i=1;i<=n;i++)
{
f=(f+m)%i;
}
printf("%d\n",f+1);
return 0;
}