Redian新闻
>
What does C++ program return to the operating system?
avatar
What does C++ program return to the operating system?# Programming - 葵花宝典
S*H
1
What is the correct value to return to the operating system upon the
successful completion of a program?
A. -1
B. 1
C. 0
D. Programs do not return a value.
avatar
t*t
2
没听说过有硬性规定,只有常用的约定,而且跟C++也毫无关系

【在 S*****H 的大作中提到】
: What is the correct value to return to the operating system upon the
: successful completion of a program?
: A. -1
: B. 1
: C. 0
: D. Programs do not return a value.

avatar
S*H
3
The given answer is 0. No explanation is given.
I do not undertand why.
avatar
t*t
4
常用的约定的确就是0.但是也并不规定一定要这样做.

【在 S*****H 的大作中提到】
: The given answer is 0. No explanation is given.
: I do not undertand why.

avatar
u*u
5
you can return anything, nothing in the system cares about this value.

【在 S*****H 的大作中提到】
: What is the correct value to return to the operating system upon the
: successful completion of a program?
: A. -1
: B. 1
: C. 0
: D. Programs do not return a value.

avatar
O*d
6
Usually you return 0 for success, non-zero for errors. An invoking program,
say a perl script, may check the returned value.
相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。