`
aerchi
  • 浏览: 427798 次
  • 性别: Icon_minigender_1
  • 来自: 昆明
文章分类
社区版块
存档分类
最新评论

ARGUMENTS 和 PARAMETER的区别

阅读更多
看《TIJ》时老看到“引数”这个词,觉得怪别扭的,但一直没去查引数和参数有何区别,先查资料终于明白了:
1.http://blog.chinaunix.net/u/25073/showart_188475.html
一般说来,两个是可以互换的。但是 C 程序员的习惯是:parameter 是参数,而 argument 是参数的值。也就是说,函数原型的参数列表,是 parameter list,比如

int sum(int a, int b);

而当使用的时候

int sum;
sum = sum(10, 20);

10 和 20 则是 argument。

这个习惯也影响了很多其他语言的程序员。如果要混合两者的意义,一般用 argument,而 parameter 则比较少用。

argument 有的时候也被称作 actual parameter。

对应的中文术语是

parameter = 形参 (估计是「形式参数」简称)
argument = 实参 (估计是「实际参数」简称)


2.http://royfang.spaces.live.com/blog/cns!53F57C7F0CE9D52C!125.entry
argument和parameter是有区别的,过去的资料中统一翻译为参数是不准确的,前者翻译成引数,后者翻译成参数,这样的翻译才是精确的翻译,两者的区别如下文:
What is the difference between an argument and a parameter?
引数和参数有何区别?
While defining method, variables passed in the method are called parameters.
当定义方法时,传递到方法中的变量称为参数.
While using those methods, values passed to those variables are called arguments.
当使用方法时,传给变量的值称为引数.
分享到:
评论

相关推荐

    理解Javascript函数形式参数与arguments

    理解Javascript函数形式参数与arguments

    py-paramstore:用于操纵AWS Parameter Store参数的Python工具

    py-paramstore.py [-h] [-p PROFILE | -a ARN] [-r] [-x] [-f FILE] [-g] [-u] [--region REGION] [-q] keypositional arguments: key Parameter Store Key or 'Tree' to manipulateoptional arguments: -h, --help...

    oracle.net.ca.NetCA $* p8670579_112010_LINUX.zip

    Parameter "responsefile" = /oracle/database/response/netca.rsp Done parsing command line arguments. Oracle Net Services Configuration: Profile configuration complete. Oracle Net Listener Startup:...

    Eclipse下PeerSim仿真

    Arguments:在Program arguments中输入config-example1.txt,也就是配置文件。 (7)第6步完成之后,点击运行,会出现错误: peersim.config.IllegalParameterException: Parameter "protocol.lnk": The class ...

    Python基础教程:函数参数和注解.pdf

    Python基础教程:函数参数和注解 四种参数 Python函数func定义如下: def func(first, *args, second="Hello World", **kwargs): print(first) print(args) print(second) print(kwargs) func("lisi", "san", py=...

    2009 达内Unix学习笔记

    命令和参数之间必需用空格隔开,参数和参数之间也必需用空格隔开。 一行不能超过256个字符;大小写有区分。 二、特殊字符含义 文件名以“.”开头的都是隐藏文件/目录,只需在文件/目录名前加“.”就可隐藏它。...

    cachedcall:缓存慢函数调用的结果-matlab开发

    用法:[a,b,...]=cachedcall(fun[,Arguments,parameter,value]) 输入: fun: 函数的句柄,其输出应该被缓存。 参数:包含所有应传递给 fun 的参数的单元格。 可选的命名参数: CacheFolder:缓存结果的文件夹。 ...

    delphi编译错误.txt

    Constants cannot be used as open array arguments 常量不能用作打开数组参数 Constructing instance of ''''<name>'''' containing abstract methods 构造的实体包含抽象的方法 Could not compile used unit ''''...

    matlab输入分子和分母表达式直接得出乃氏图和博德图

    matlab输入分子和分母表达式直接得出乃氏图和博德图 %Welcome to use getnyquist. %It's a function helping you to get nyquist chart without inputing any parameter but only a formula. %This .m file can only...

    Matlab有限元网格化源程序-ddd.m

    • The parameter h0 is the distance between points in the initial distribution p0. For uniform meshes = constant), the element size in the final mesh will usually be a little larger than this input....

    Matlab有限元网格化源程序-huniform.m

    • The parameter h0 is the distance between points in the initial distribution p0. For uniform meshes = constant), the element size in the final mesh will usually be a little larger than this input....

    Matlab有限元网格化源程序-dcircle.m

    • The parameter h0 is the distance between points in the initial distribution p0. For uniform meshes = constant), the element size in the final mesh will usually be a little larger than this input....

    Matlab有限元网格化源程序-distmesh2d.m

    • The parameter h0 is the distance between points in the initial distribution p0. For uniform meshes = constant), the element size in the final mesh will usually be a little larger than this input....

    JavaScript 函数参数

    functionName(parameter1, parameter2, parameter3) { // 要执行的代码…… } 函数显式参数在函数定义时列出。 函数隐式参数在函数调用时传递给函数真正的值。 参数规则 JavaScript 函数定义显式参数时没有指定...

    jasperwrapper:适用于PHP的薄JasperReports包装器

    用法usage: JasperWrapper.jar [arguments] [[key] [value] ...]arguments: ( --{argument}={parameter} )dbdriver javaClass for DBConnectdburl connection String for DBdbuser user for DBConnectdbpass ...

    masm的ml.exe错误信息中文对照

    assembler limit : macro parameter name table full 汇编限制:宏参数名表已满 invalid command-line option 无效命令行参数 nesting level too deep 嵌套过深 unmatched macro nesting 不正确的宏嵌套 line too ...

    josephUglify:Js和Css全选件浏览器端uglifier

    约瑟夫·丑化 Js和Css全选件浏览器端uglifier / ** src可以是文件的对象 var code = {“ file1.js”:... arguments (default: true) -- replace arguments[index] with function parameter name whenever possible.

    elasticsearch-py-6.3.1.pdf

    You can customize this behavior by passing parameters to the Connection Layer API (all keyword arguments to the Elasticsearch class will be passed through). If what you want to accomplish is not ...

    CmdLine:命令行参数解析器实用程序

    CmdLine.Option o1 = new CmdLine.Option('f', "file", "File parameter.", false ); CmdLine.Option flag1 = new CmdLine.Option('v', "verbose", "Print verbose output." , true, "FALSE"); CmdLine.Args args...

    ButterFly:ButterFly 是一个支持多种标准的 Java 命令行参数解析器

    // construct array of strings to simulate command-line arguments// constrcut the Parser// the second parameter of POSIXParser are an array of arguments that you are interested in.Parser p = new ...

Global site tag (gtag.js) - Google Analytics