字符串内排序 (C++代码) (冒泡排序) 摘要:#include "iostream" #include "algorithm" #include "string" #include "cstdio" using namespace std…… 题解列表 2018年08月02日 1 点赞 0 评论 1246 浏览 评分:8.0
字符串内排序 (Java代码) 摘要:import java.util.Arrays; import java.util.Scanner; public class Main { public static void ma…… 题解列表 2022年06月12日 0 点赞 0 评论 261 浏览 评分:6.0
字符串内排序-题解(C语言代码)超级好理解 摘要:#include #include int main() { int i,j; char a[220]; while(gets(a))//多次循环的条件 { …… 题解列表 2019年07月30日 0 点赞 0 评论 639 浏览 评分:0.0
使用scanf读取空格,在多次读取时候需要把\n用getchar()读取,不然会产生死循环 摘要:#define_CRT_SECURE_NO_WARNINGS1#include<stdio.h>charstr[210];int…… 题解列表 2025年09月17日 0 点赞 0 评论 41 浏览 评分:0.0
使用gets不能使用fgets,原因:笔者认为第二个测试用例太长了,超过了一行,因此使用gets无限制读取,直到读到空格和回撤符号 摘要:#include<stdio.h>#include<string.h>#include<stdlib.h>int compare(const void *p1,co…… 题解列表 2025年09月08日 0 点赞 0 评论 122 浏览 评分:0.0
字符串内排序 vector 摘要:解题思路:注意事项:参考代码:#include"bits/stdc++.h" using namespace std; int main(){ // 定义一个字符串变量,用于存储输入的一…… 题解列表 2024年12月09日 0 点赞 0 评论 153 浏览 评分:0.0
不要使用scanf函数,因为scanf不存储空格 摘要:这道题我最开始使用scanf输入,然后提交只能过50% ```c #include #include #include int cmp(const void *a,const void…… 题解列表 2024年08月01日 0 点赞 0 评论 423 浏览 评分:0.0
字符串内排序 (C++代码) 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h> using namespace std; int main(){ char s[200],t; int i,…… 题解列表 2018年07月15日 1 点赞 0 评论 919 浏览 评分:0.0
C++代码实现 摘要:解题思路:sort排序,C++代码实现注意事项:参考代码:#include<iostream>#include<algorithm>#include<string>using namespace st…… 题解列表 2023年12月13日 0 点赞 0 评论 176 浏览 评分:0.0
字符串内排序 (选择排序) 摘要:解题思路:本题采用选择排序法。第一趟找出字符串中最小的字符,然后从该字符后重新找到最小字符。以此类推。注意事项:参考代码:char a[200];// int n; char t; while (ge…… 题解列表 2023年01月15日 0 点赞 0 评论 208 浏览 评分:0.0