mirror of
https://github.com/Kiritow/OJ-Problems-Source.git
synced 2024-03-22 13:11:29 +08:00
Create 1372.cpp
This commit is contained in:
parent
0713bc5744
commit
654dfd1c05
14
QUSTOJ/1372.cpp
Normal file
14
QUSTOJ/1372.cpp
Normal 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;
|
||||
}
|
Loading…
Reference in New Issue
Block a user