首页 > 其他 > 详细

c-参数(argument)

时间:2014-08-22 15:45:59      阅读:373      评论:0      收藏:0      [点我收藏+]

  In  C,  array arguments behave as though they are passed by reference, and scalar variables and constants are passed by value (like var parameters and value parameters, respectively, in Pascal or Modula).

  Thus, any changes made by a function to a scalar argument are lost when the function returns; the function cannot change the value of the calling program?s argument in this manner.

  When a function changes the value of an element of an array argument, however, the array in the calling program is actually modified. 

c-参数(argument)

原文:http://www.cnblogs.com/listened/p/3929334.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!