题解 1118: Tom数
摘要:解题思路:使用 int的话只能对一半,使用数组来存取数才可以存下去很大的数注意事项:参考代码:#include <stdio.h>#include <string.h>int main(){ ch……
1118: Tom数-题解(python)
摘要:解题思路:注意事项:参考代码:while True: a = input() l = [] for i in a: l.append(int(i)) m = su……
C++简单易懂,整除和取余
摘要:解题思路:看代码注释!!!参考代码:#include<bits/stdc++.h>
using namespace std;
int main(){
long long n;
whil……
编写题解 1118: Tom数
摘要:解题思路:注意事项:参考代码:while True: try: n = str(input()) sum = 0 for i in n: ……
无穷大也可以算,不需要数组
摘要:int main(){
char c;
int state = 0;
int sum = 0;
while((state = scanf("%c", &c)) != EOF){
……
Hifipsysta-1118题-Tom数(C++代码)字符串法
摘要:
```cpp
#include
#include
#include
using namespace std;
int main(){
string str;
wh……
1118: Tom数 java代码
摘要:应该算作入门题, 不应该放在这里
```actionscript
import java.util.Scanner;
public class Main {
public static ……
Tom数(我来用Java写)
摘要:解题思路: 将字符串变成字符数组,再变成一个个单字母的字符串,最后用Integer.valueOf()变成整型。注意事项:注意要用long来表示,防止超界。参考代码:import java.util.……