码迷,mamicode.com
首页 > 其他好文 > 详细

const int *

时间:2015-10-09 12:12:00      阅读:120      评论:0      收藏:0      [点我收藏+]

标签:

5.Please choose the right statement about constusage:

  A.const int a;//const interger

  B.int const a;//const integer

  C.int const *a;//a pointer while point to const interger

  D.const int *a;//a const pointer which point to interger

  E.int const *a;//a const pointer which point to interger

解析:

  正确答案:ABC

  对于A和B,int const和const int可以颠倒位置,意义不变

  CDE都表示const int的指针,而int *const a才表示指向int的const指针。

 

const int *

标签:

原文地址:http://www.cnblogs.com/QoQian/p/4863366.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!