python 知识点:字符统计 简单易懂 摘要:解题思路:学习python第一天注意事项: python的在线编译器用不了参考代码:# 字符串的统计 str.count('字符串') 输出为int类型的个数str=input()a0…… 题解列表 2023年07月11日 0 点赞 1 评论 670 浏览 评分:4.7
2846: 统计数字字符个数 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;typedef long long ll;int main(){ string s…… 题解列表 2024年07月13日 0 点赞 0 评论 586 浏览 评分:0.0
统计数字字符个数java 摘要:解题思路:注意事项:参考代码:package arrLast; //题目 2846: 统计数字字符个数 import java.util.Scanner; public class t_2846…… 题解列表 2024年02月06日 1 点赞 0 评论 626 浏览 评分:0.0
2846: 统计数字字符个数 摘要:参考代码:s = input() sum = 0 for i in s: if i.isdigit(): sum += 1 print(sum)…… 题解列表 2024年03月23日 0 点赞 0 评论 925 浏览 评分:0.0
解 2846: 统计数字字符 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;char a[1005];int main(){ int sum=0; cin.g…… 题解列表 2024年07月11日 0 点赞 0 评论 533 浏览 评分:0.0
2846: 统计数字字符个数 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;const int N=1e5;char a[N];int main(){ …… 题解列表 2024年07月11日 0 点赞 0 评论 594 浏览 评分:0.0
2846: 统计数字字符个数 ```cpp#includeusingnamespacestd;typedeflonglongll;constintN=1e5;chara[N];intmain(){llsum=0;cin.getline(a,225);for(inti=0;i='0'&&a[i] 题解列表 2024年07月12日 0 点赞 0 评论 531 浏览 评分:0.0
莉露C++编写题解 2846: 统计数字字符个数 解题思路:getline原句,for挨个判断,sizeof(s)=strlen(s)+1,但C++不可用strlen。注意事项:if(s[i]>=48&&s[i]<=57)可写作if(s[i]>='0'&&s[i]<='9')sizeof(s)-1可写作s.size() 题解列表 2026年02月27日 0 点赞 0 评论 268 浏览 评分:0.0
2846: 统计数字字符个数 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;typedef long long ll;const int N = 1e7;ch…… 题解列表 2024年07月18日 0 点赞 0 评论 831 浏览 评分:0.0
优质题解,回归真神的初始途径 摘要:解题思路:注意事项:参考代码:chuan=input()j=0for fu in chuan: if fu.isdigit(): j+=1print(j)…… 题解列表 2024年07月25日 0 点赞 0 评论 1009 浏览 评分:0.0