hdu 1040 As Easy As A+B(排序)
题意:裸排序
思路:排序
#include<iostream>
#include<stdio.h>
#include<algorithm>
using namespace std; int a[]; int main(){
int t,n,i;
scanf("%d",&t);
while(t--){
scanf("%d",&n);
for(i=;i<n;++i)
scanf("%d",&a[i]);
sort(a,a+n);
for(i=;i<n-;++i)
printf("%d ",a[i]);
printf("%d\n",a[i]);
}
return ;
}
hdu 1040 As Easy As A+B(排序)的更多相关文章
- HDU 1040 As Easy As A+B(排序)
As Easy As A+B Problem Description These days, I am thinking about a question, how can I get a probl ...
- HDU 1040 As Easy As A+B (排序。。。水题)
题意:给定n个数,让你从小到大排序. 析:不说什么了. 代码如下: #include <cstdio> #include <iostream> #include <cst ...
- HDU 1040.As Easy As A+B【排序】【如题(水!水!水!)】【8月24】
As Easy As A+B Problem Description These days, I am thinking about a question, how can I get a probl ...
- hdu 1040 As Easy As A+B
As Easy As A+B Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) T ...
- HDU 1040 As Easy As A+B [补]
今天去老校区找她,不想带电脑了,所以没时间A题了 /*******************************************************************/ As Ea ...
- HDU 5572 An Easy Physics Problem (计算几何+对称点模板)
HDU 5572 An Easy Physics Problem (计算几何) 题目链接http://acm.hdu.edu.cn/showproblem.php?pid=5572 Descripti ...
- 杭电 1040 As Easy As A+B 【排序】
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1040 解题思路:数据不大,可以直接用冒泡排序 #include<stdio.h> int ...
- hdu 5058 So easy
题目连接 http://acm.hdu.edu.cn/showproblem.php?pid=5058 So easy Description Small W gets two files. Ther ...
- hdu 5475 An easy problem(暴力 || 线段树区间单点更新)
http://acm.hdu.edu.cn/showproblem.php?pid=5475 An easy problem Time Limit: 8000/5000 MS (Java/Others ...
随机推荐
- Ubuntu 16.04安装MongoDB的GUI工具RoboMongo
一.下载: https://robomongo.org/download 离线版本:(链接: https://pan.baidu.com/s/1mirFi56 密码: y3t2) 二.安装: -lin ...
- CodeSign error: code signing is required for product type 'Application' in SDK 'iOS 7.0'
这个一般是证书设置的问题, 在build settings中找到 Code Signing->Code Signing Identity修改成有效的证书即可
- js利用offsetWidth和clientWidth来计算滚动条的宽度
原文: http://www.haorooms.com/post/js_scroll_width 参考: https://www.cnblogs.com/benxiaohai-microcosm/p/ ...
- 转: 浅析Fusion-IO和Intel SSD
from: http://alanwu.blog.51cto.com/3652632/865235 标签:SSD 原创作品,允许转载,转载时请务必以超链接形式标明文章 原始出处 .作者信息和本声明.否 ...
- Java常见面试题汇总(一)
1)什么是Java虚拟机?为什么Java被称作是"平台无关的编程语言"? Java虚拟机是一个能够运行Java字节码的虚拟机进程.Java源文件被编译成能被Java虚拟机运行的字节 ...
- 判断用户Input输入的事件来进行登陆
我们是通过键盘按的object.keyCode获取的 Html <input onkeydown="keydownMsg(event)" type="text&qu ...
- C中的预编译编译链接
http://ke.qq.com/webcourse/index.html#course_id=67888&term_id=100058920&taid=13934591901 ...
- VueJS表达式支持:逻辑控制或运算
HTML <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <titl ...
- error MSB8011: 未能注冊输出。请尝试启用“逐用户重定向”
初试MFC就遇到困难了.vs2010创建一个MFC ActiveX控件项目. 什么都还没做呢,就出现故障了? 郁闷呀.! ! 1>C:\Program Files\MSBuild\Microso ...
- muduo::Connector、TcpClient分析
Connector TcpClient Connector Connector用来发起连接. 在非堵塞网络中,主动发起连接比被动接收连接更为复杂,由于要考虑错误处理,还要考虑重试. 主要难点在于 1. ...