莉露C语言编写题解 2863: 删除单词后缀 摘要:解题思路:暴力破解注意事项:str[strcspn(str,"\n")] = '\0';,否则会把\n算进去,er消不掉参考代码:#include<stdio…… 题解列表 2026年03月30日 0 点赞 0 评论 39 浏览 评分:0.0
2863: 删除单词后缀(暴力解法) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<string.h>int main(){ char a[100]; scanf("%s",a); i…… 题解列表 2024年11月10日 2 点赞 0 评论 465 浏览 评分:10.0
删除单词后缀 摘要:解题思路:注意事项:参考代码:// 使用预处理指令定义宏,以禁用编译器的安全警告 #define _CRT_SECURE_NO_WARNINGS // 包含标准输入输出库的头文件 #incl…… 题解列表 2023年11月27日 0 点赞 0 评论 441 浏览 评分:0.0
删除单词后缀(巧秒解题,我们可以利用strlen()获得单词长度,如果单词后面出现那些后缀情况,只需要缩短长度,循环输出每个字符就好了) 摘要:解题思路:注意事项:去掉后缀后,要注意单词长度不能为0,否则不删参考代码:#include<stdio.h> #include<string.h> int main() { char a[3…… 题解列表 2023年10月25日 0 点赞 0 评论 360 浏览 评分:0.0
c语言代码解决问题 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<string.h>int main(){ char str[33]; gets(str); str[strlen(st…… 题解列表 2023年06月07日 0 点赞 0 评论 412 浏览 评分:0.0
巧妙运用'\0' 摘要:```c #include #include #include int main() { int n,flag=0; char a[100], b[100]; gets_s(a)…… 题解列表 2023年02月01日 0 点赞 0 评论 663 浏览 评分:9.9
2863: 删除单词后缀 摘要:解题思路:注意事项:参考代码:#include <stdio.h> #include <string.h> int main() { char a[205] = "\0"; …… 题解列表 2022年10月26日 0 点赞 0 评论 563 浏览 评分:6.0