1035: [编程入门]自定义函数之字符类型统计(python) 摘要:### 代码如下 ~~~python a = [0] * 4 for i in input(): if i.isalpha(): a[0] += 1 e…… 题解列表 2024年10月15日 1 点赞 0 评论 248 浏览 评分:9.9
正则表达式实现:字符类型统计 简单易懂 (Java代码) 摘要:解题思路: 依次遍历字符,利用正则表达式进行字符匹配,满足则对应计数器加一注意事项:参考代码:import java.util.Scanner; public class Main { pu…… 题解列表 2024年10月14日 0 点赞 0 评论 265 浏览 评分:0.0
[编程入门]自定义函数之字符类型统计 摘要:```java import java.util.Scanner; public class Main { public static void main(String[] args) {…… 题解列表 2024年08月29日 0 点赞 0 评论 266 浏览 评分:9.9
编写题解 1035: [编程入门]自定义函数之字符类型统计 摘要:解题思路:注意事项:参考代码:#include <iostream>using namespace std;void a(string s){ int sum1=0,sum2=0,sum3=0,…… 题解列表 2024年07月23日 0 点赞 0 评论 258 浏览 评分:0.0
字符统计两种方式(C语言) 摘要:方法区别:第一种:输出在自定义函数中第二种:输出在主函数中注意事项:使用scanf函数输入时,不能用 "%s" ,因为输入空格后输出只会显示空格之前的内容,所以要用 "%[^\n]" ,表示除了回车键…… 题解列表 2024年07月23日 0 点赞 0 评论 310 浏览 评分:0.0
自定义函数之字符类型统计 摘要:解题思路:注意事项:参考代码:def tongji(m): a,b,c,d = 0,0,0,0 for i in m: if i.isalpha(): …… 题解列表 2024年06月04日 0 点赞 0 评论 159 浏览 评分:0.0
无聊的星期六 摘要:n=input() l1=l2=l3=l4=0 for i in range(len(n)): if n[i].isspace(): l1+=1 elif n…… 题解列表 2024年05月25日 0 点赞 0 评论 332 浏览 评分:0.0
1035 字符类型统计(选择语句分别统计) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<stdlib.h>#include<string.h>int main(){ char s[100]; gets(s)…… 题解列表 2024年05月16日 0 点赞 0 评论 293 浏览 评分:0.0
编写题解 1035: [编程入门]自定义函数之字符类型统计 摘要:解题思路:注意事项:参考代码:#include<stdio.h> #include<stdlib.h> #include<string.h> void count(char* str,int* …… 题解列表 2024年05月13日 0 点赞 0 评论 136 浏览 评分:6.0
编程入门]自定义函数之字符类型统计 摘要:解题思路:注意事项:参考代码:#include<stdio.h>void Statistic(char* str,int n){ int i; int character = 0; int numbe…… 题解列表 2024年05月07日 0 点赞 0 评论 140 浏览 评分:0.0