“空对”的含义括号? [英] meaning of "empty pair" of parenthesis ?
问题描述
这是来自Steve Summit C的笔记:
空的括号表示我们的主函数接受
没有参数,也就是说,没有参数调用函数时,传入的任何信息都需要传递给b
。 [1]
我想,一个空对括号表示函数可以采用
无限数量的参数
[1] http://www.eskimo.com/~scs/cclass/notes/sx1a.html
this is from Steve Summit C notes:
The empty pair of parentheses indicates that our main function accepts
no arguments, that is, there isn''t any information which needs to be
passed in when the function is called. [1]
i think, an "empty pair" of parenthesis means a function can take
unlimited number of arguments
[1] http://www.eskimo.com/~scs/cclass/notes/sx1a.html
推荐答案
arnuld写道:
arnuld wrote:
这是来自Steve Summit C的说明:
空括号表示我们的主函数接受
没有参数,也就是说,没有任何信息需要
在调用函数时传入。 [1]
我想,一个空对括号表示函数可以采用
无限数量的参数
this is from Steve Summit C notes:
The empty pair of parentheses indicates that our main function accepts
no arguments, that is, there isn''t any information which needs to be
passed in when the function is called. [1]
i think, an "empty pair" of parenthesis means a function can take
unlimited number of arguments
不在C定义中它不会。也不在声明中。
-
克里斯电刺猬 Dollin
这些快捷方式都是人们使用它们。
Not in a C definition it doesn''t. Nor in a declaration.
--
Chris "electric hedgehog" Dollin
The shortcuts are all full of people using them.
arnuld说:
arnuld said:
这是来自Steve Summit C的注释:
空的括号表示我们的主函数接受
没有参数,是的,调用函数时,没有任何信息需要传递给
。 [1]
this is from Steve Summit C notes:
The empty pair of parentheses indicates that our main function accepts
no arguments, that is, there isn''t any information which needs to be
passed in when the function is called. [1]
史蒂夫是正确的。 (更确切地说,我们的主函数不接受
参数。但这是一个很好的观点。)
Steve is correct. (More precisely, our main function accepts no
parameters. But it''s a fine point.)
i think,anempty对"括号意味着一个函数可以采取
无限数量的参数
i think, an "empty pair" of parenthesis means a function can take
unlimited number of arguments
但史蒂夫只是解释了它的含义!你有什么理由相信史蒂夫错了?
-
Richard Heathfield
Usenet是一个奇怪的地方 - dmr 29/7/1999
http://www.cpax.org.uk
电子邮件:rjh在上述域名中, - www。
But Steve just explained what it means! What grounds do you have for
believing that Steve is wrong?
--
Richard Heathfield
"Usenet is a strange place" - dmr 29/7/1999
http://www.cpax.org.uk
email: rjh at the above domain, - www.
" arnuld" < ge ********* @ gmail.comwrote in message
news:11 ******************** @ l75g2000hse.googlegrou ps.com ...
"arnuld" <ge*********@gmail.comwrote in message
news:11********************@l75g2000hse.googlegrou ps.com...
这是来自Steve Summit C笔记:
一对空的括号表示我们的主函数
不接受任何参数,也就是说,在调用函数时,没有任何信息需要传递给
。 [1]
我想,一个空对括号表示函数可以取
无限数量的参数
this is from Steve Summit C notes:
The empty pair of parentheses indicates that our main function
accepts no arguments, that is, there isn''t any information which
needs to be passed in when the function is called. [1]
i think, an "empty pair" of parenthesis means a function can take
unlimited number of arguments
考虑:
void foo();
void bar(void);
void baz(){}
foo是一个需要的函数一个未指定数量的参数。 bar和
baz都是零参数的函数。看到差异?
(这并不是很有意义,因为它是C的历史神器。
C ++更加理智;如果你学会了C ++规则,认为它们是C规则,
你会非常困惑.C ++不是C.)
S
-
Stephen Sprunk那些认为他们知道一切的人
CCIE#3723对我们这些人来说是一个很大的烦恼。
K5SSS --Isaac Asimov
-
通过免费的Usenet帐户从 http://www.teranews.com
Consider:
void foo();
void bar(void);
void baz() {}
foo is a function that takes an unspecified number of arguments. bar and
baz are both functions that take zero arguments. See the differences?
(This doesn''t make perfect sense because it''s a historical artifact of C.
C++ is much saner; if you learned the C++ rules thinking they were C rules,
you''ll be very confused. C++ is not C.)
S
--
Stephen Sprunk "Those people who think they know everything
CCIE #3723 are a great annoyance to those of us who do."
K5SSS --Isaac Asimov
--
Posted via a free Usenet account from http://www.teranews.com
这篇关于“空对”的含义括号?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!