OJ-Problems-Source/HDOJ/2114_autoAC.cpp

12 lines
219 B
C++
Raw Normal View History

#include <stdio.h>
int main()
{
__int64 n,s;
while(~scanf("%I64d",&n))
{
s=((n*(n+1)/2%10000)*(n*(n+1)/2%10000))%10000;
printf("%04I64d\n",s);
}
return 0;
}