逆序输出
来源:互联网 发布:潘安到底有多帅 知乎 编辑:程序博客网 时间:2024/06/06 20:41
#include <stdio.h>int main(){ int i = 0; int arr[9]={1,2,3,4,5,6,7,8,9}; int len=sizeof(arr)/sizeof(arr[0]); int *l=arr; int *r=arr+len-1; while( l < r ){ int tmp = *l; *l = *r; *r = tmp; l++; r--;} for(i = 0;i<len;i++) {printf("%d ",arr[i]); }
return 0;}
0 0
- 逆序输出
- 逆序输出
- 逆序输出
- 逆序输出
- 逆序输出
- 逆序输出
- 逆序输出
- 逆序输出
- 逆序输出
- 逆序输出
- 逆序输出
- 逆序输出
- 字符串逆序&字符串逆序输出
- 单链表逆序或者逆序输出
- HTML 逆序输出 输出引号
- 逆序输出字符串
- list循环逆序输出
- 字符串逆序输出
- DSP28335—CMD文件中的各个段解释
- CSS z-index 属性的使用方法和层级树的概念
- 在ASP.NET中使用JSON
- Mysql errno:150
- SVMlight windows使用
- 逆序输出
- jquery 多维数组实现PHP的count、in_array(不区分大小写),utf8字符串(包含中文,中文字符2个字节)字节统计
- WPF中使用webbrowser调用javascript代码
- svn
- openCV 直方图比较compareHist函数
- Red Hat Enterprise Linux 5 64位安装Mysql5.6.24(DB5.6.24.rpm for rhel5 x86)
- 排列数组
- UVA - 116 - Unidirectional TSP (简单DP + 打印路径)
- POJ1002 题解