而(假){} [英] while(false) { }

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

问题描述

大家好,


任何人都可以告诉我这句话的含义,

while(false){

do_something();

}



这意味着什么,以及虚假条件来自哪里。此外,该声明如何在程序中执行。


提前感谢。


sokoun。

Hi all,

can anyone tell me what this statement means,

while(false){
do_something();
}


what it means, and where the false condition come from. moreover, how this statement execute in the program.

thanks in advance.

sokoun.

推荐答案


大家好,


任何人都可以告诉我这句话的含义,
while(false){

do_something();

}



含义如何,以及虚假情况的来源。此外,这个声明如何在节目中执行。


提前感谢。


sokoun。
Hi all,

can anyone tell me what this statement means,

while(false){
do_something();
}


what it means, and where the false condition come from. moreover, how this statement execute in the program.

thanks in advance.

sokoun.



您好sokoun,请告诉我您认为这段代码有什么作用?


Savage

Hi sokoun,tell me what do you think that this piece of code do?

Savage



大家好,


任何人都可以告诉我这句话的含义,

while(false){

do_something();

}



这意味着什么,以及假情况来自何处。此外,这个声明如何在节目中执行。


提前感谢。


sokoun。
Hi all,

can anyone tell me what this statement means,

while(false){
do_something();
}


what it means, and where the false condition come from. moreover, how this statement execute in the program.

thanks in advance.

sokoun.




嘿它只是语法花花公子..

u必须写条件为true / fasle

和condn check后要执行的语句..


无论如何你想做什么..?




hey its just syntax dude..
u have to write condition true/fasle
and the statements to be executed after condn check..

anyway what do u want to do..?


false是一个错误的条件,在C语言中它意味着0而1是真的,因为c不包括布尔值。

假设你有这个代码:

false is a false condition , in C language it means 0 while 1 is true, because c does not include booleans.
suppose you have this code:

展开 | 选择 | Wrap | 行号


这篇关于而(假){}的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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