当前位置:网站首页>Huawei 0 foundation - image sorting
Huawei 0 foundation - image sorting
2022-07-06 18:25:00 【Full stack programmer webmaster】
Hello everyone , I meet you again , I'm the king of the whole stack .
Source program :
#include<iostream>
#include<string>
using namespace std;
//const int max=1024;
int main()
{
char s[1024];
char temp;
gets(s);
int len;
len=strlen(s);
for(int i=0;i<len;i++)
{
for(int j=i+1;j<len;j++)
{
if(s[i]>s[j])
{
temp=s[i];s[i]=s[j];s[j]=temp;
}
}
}
puts(s);
return 0;
}
Execution results :
summary : very easy~0 Base title ~
Copyright notice : This article is an original blog article , Blog , Without consent , Shall not be reproduced .
Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/117396.html Link to the original text :https://javaforall.cn
边栏推荐
- Compilation Principle -- C language implementation of prediction table
- AFNetworking框架_上传文件或图像server
- 关于这次通信故障,我想多说几句…
- STM32 key state machine 2 - state simplification and long press function addition
- celery最佳实践
- The third season of Baidu online AI competition is coming in midsummer, looking for you who love AI!
- Jerry's access to additional information on the dial [article]
- Implementation of queue
- 【中山大学】考研初试复试资料分享
- MS-TCT:Inria&SBU提出用于动作检测的多尺度时间Transformer,效果SOTA!已开源!(CVPR2022)...
猜你喜欢
传输层 拥塞控制-慢开始和拥塞避免 快重传 快恢复
Take you through ancient Rome, the meta universe bus is coming # Invisible Cities
std::true_ Type and std:: false_ type
Jerry is the custom background specified by the currently used dial enable [chapter]
Open source and safe "song of ice and fire"
Alibaba cloud international ECS cannot log in to the pagoda panel console
J'aimerais dire quelques mots de plus sur ce problème de communication...
【中山大学】考研初试复试资料分享
Interesting - questions about undefined
Jerry's updated equipment resource document [chapter]
随机推荐
解读云原生技术
Markdown syntax for document editing (typera)
推荐好用的后台管理脚手架,人人开源
44所高校入选!分布式智能计算项目名单公示
STM32+MFRC522完成IC卡号读取、密码修改、数据读写
图片缩放中心
模板于泛型编程之declval
2022暑期项目实训(一)
CSRF漏洞分析
celery最佳实践
Automatic reservation of air tickets in C language
Jerry is the custom background specified by the currently used dial enable [chapter]
Shangsilicon Valley JUC high concurrency programming learning notes (3) multi thread lock
首先看K一个难看的数字
Coco2017 dataset usage (brief introduction)
287. Find duplicates
STM32 key state machine 2 - state simplification and long press function addition
使用cpolar建立一个商业网站(1)
IP, subnet mask, gateway, default gateway
Windows连接Linux上安装的Redis