sizeof 另类
来源:互联网 发布:stm8烧写软件 编辑:程序博客网 时间:2024/04/28 12:44
static char *strings[] ={
"this is string one",
"this is string two",
"this is string three",
};
const int string_no = ( sizeof strings ) / ( sizeof strings[0] );
sizeof strings =12 ?????
sizeof strings[0]=4 ?????
string_no =3 ???
char *strings1XXXX[] ={
"thisisstringone",
"thisisstring two",
"this is stringthree",
};
int test =sizeof (strings1XXXX); //12
int string_no1 = (test ) / ( sizeof (strings1XXXX[0]) ); //3
看到这明白了,int test =sizeof (strings1XXXX); 实际把它看成是三个字符串指针来处理的!!!
shit !
0 0
- sizeof 另类
- SIZEOF
- Sizeof
- sizeof
- sizeof
- sizeof
- sizeof
- sizeof
- sizeof............
- sizeof
- sizeof
- sizeof
- sizeof
- sizeof
- sizeof
- sizeof
- sizeof
- sizeof
- iStylePDF在线阅读编辑控件在多浏览器(IE,firefox,chrome,opera等)中的使用
- 两个android程序间的相互调用(apk互调)
- EasyUI Pagination 分页的两种做法
- Vim 快捷键整理<转>
- Android开发的技术层次
- sizeof 另类
- 大三期末考试,蛋疼的节奏,英语四级还没过,这两天一直在装系统,
- UIView histTest:withEvent: 解析
- 为看球辞职的最新相关信息
- swift UISlider
- iOS如何实现传值---协议传值
- CocoStudio实例
- nginx负载均衡配置
- 我的csdn博客搬家了