函数srand [英] srand

查看:98
本文介绍了函数srand的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对不起。

句子或函数下面的句子;

srand(time(NULL));

Excuse me.
Is the sentence below a statement or a function;
srand(time(NULL));

推荐答案

Lynn写道:
Lynn wrote:

>

句子或函数下面的句子;


srand(time(NULL));
>
Is the sentence below a statement or a function;

srand(time(NULL));



由于srand是一个void函数,它是一个函数调用,它不会返回一个值。 C函数是特殊的,因为它们包括

什么是其他语言的程序。函数的调用

是一个声明。


-

[邮件]:Chuck F(cinefalconer at maineline dot net)

[page]:< http://cbfalconer.home.att.net>

尝试下载部分。

Since srand is a void function, it is a function call that does not
return a value. C functions are peculiar, in that they include
what are procedures in other languages. The call of the function
is a statement.

--
[mail]: Chuck F (cbfalconer at maineline dot net)
[page]: <http://cbfalconer.home.att.net>
Try the download section.


CBFalconer< cbfalco ... @ yahoo.comwrote:
CBFalconer <cbfalco...@yahoo.comwrote:

Lynn写道:
Lynn wrote:

下面的句子是一个陈述或一个函数;
Is the sentence below a statement or a function;



您可能想解释一下_you_想法和原因。
如上所述,您的问题看起来就像是家庭作业。< br>

You might like to explain what _you_ think and why.
As stated, your question just looks like homework.


srand(time(NULL));
srand(time(NULL));



由于srand是一个void函数,它是一个函数

调用,不返回值。


Since srand is a void function, it is a function
call that does not return a value.



我不知道这是怎么相关的。

I don''t see how that''s relevant.


> * C函数是特殊的,因为它们包括

什么是其他语言的程序。
>*C functions are peculiar, in that they include
what are procedures in other languages.



你的意思是其他语言是特殊的因为它们

有一个单独的名称用于映射到

的函数空集。 ;)

You mean other languages are peculiar because they
have a separate name for functions that map to an
empty set. ;)


> *函数的调用是一个语句。
>*The call of the function is a statement.



不,这是一个表达式。至少还有一件事需要

才能作出陈述。


-

Peter

No, that''s an expression. At least one more thing
is needed to make it a statement.

--
Peter


Lynn< lo ********* @ 163.com写:
Lynn <lo*********@163.comwrites:

对不起。

句子或函数下面的句子;

srand(time(NULL));
Excuse me.
Is the sentence below a statement or a function;
srand(time(NULL));



C没有任何称为句子的东西; "线"将是一个更好的

术语。


srand和time是函数。 srand(time(NULL))是一个函数调用,

,其单个参数恰好是另一个函数调用。函数

调用是一种表达形式。表达式后跟分号

是一种陈述形式。


-

Keith Thompson(The_Other_Keith) ks *** @ mib.org < http://www.ghoti.net/~kst>

诺基亚

我们必须做点什么。这是事情。因此,我们必须这样做。

- Antony Jay和Jonathan Lynn,是部长

C doesn''t have anything called a "sentence"; "line" would be a better
term.

srand and time are functions. srand(time(NULL)) is a function call,
whose single argument happens to be another function call. A function
call is one form of expression. An expression followed by a semicolon
is one form of statement.

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
Nokia
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"


这篇关于函数srand的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆