1-3 数组的反序输出
来源:互联网 发布:java else什么意思 编辑:程序博客网 时间:2024/06/18 07:01
1-3 数组的反序输出
Time Limit: 1000MS Memory Limit: 65536KB
Submit Statistic
Problem Description
C++中数组的输入输出方法。
10个int型数组中,而后再按与输入相反的顺序输出这些数据
Input
输出内容共Enter numbers(10 int)
---Reverse output---
<p class="\"cjk\"" 0.74cm;="" margin-bottom:="" 0cm\"="" style="box-sizing: border-box; margin-top: 0px; margin-bottom: 3px;">第三行输出反序后的内容:顺序与输入顺序相反,每个数之间用一个空格间隔。Example Input
12 45 56 23 89 78 25 14 36 69
Example Output
Enter numbers(10 int)---Reverse output---69 36 14 25 78 89 23 56 45 12
Hint
#include<iostream>using namespace std;int main(){ int a[11]; cout<<"Enter numbers(10 int)"<<endl; cout<<"---Reverse output---"<<endl; for(int i = 0; i < 10; i++) cin>>a[i]; for(int j = 9; j >= 1; j--) cout<<a[j]<<" "; cout<<a[0]<<endl; return 0;}
阅读全文
0 0
- 1-3 数组的反序输出
- 1-3 数组的反序输出
- 1-3 数组的反序输出
- 1-3 数组的反序输出
- 1-3 数组的反序输出
- 1-3 数组的反序输出
- 1-3 数组的反序输出
- 1-3 数组的反序输出
- 2709 1-3 数组的反序输出
- iphone 数组的正序、反序输出。
- 反序输出正整数和求数组交集的问题
- 数组的反序
- 体验用数组反序输出0-9
- 反序输出一个int型数组中所有数组元素(数字或字符)的值
- java的treemap反序输出
- C++实现字符串数组作为函数的参数的反序输出
- 第十三周项目1——2 反序输出和数组加倍
- 数组反序对的个数
- 在别人电脑上运行本机tomcat项目的流程以及问题解决
- 习题6.5
- css:float的深度理解
- codeforces 746 Decoding
- socket阻塞与非阻塞,同步与异步、I/O模型
- 1-3 数组的反序输出
- 序列化和反序列化
- RGB转YUV色彩空间
- Azkaban3.x集群部署(multiple executor mode)
- 搭建 webrtc 信令服务器
- python基础笔记4
- 图之最小生成树-Prim算法和Kruskal算法
- N的阶乘 mod P
- Divisors UVA