题目链接:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1433 数论关于3的倍数有一个推论,就是能被9整除的数的各位和都是9.所以找到5的个数*5的最大的9的倍数,后面全补0.当然前面的判断也是需要的 #include <bits/stdc++.h> using namespace std; int n, x; int main() { // freopen("in", "r"…
Description Problem B.Last Digit Background Give you a integer number N (1<=n<=2*10100). Pleasecompute S=11+22+33+-+NN Give the last digit of S to me. Input Input file consists of several Ns, each N a line. It is ended with N=0. Output For each…