早教吧作业答案频道 -->其他-->
假设有一条绳子长3000m,每天减去一半publicclasschapter337{publicstaticvoidmain(Stringargs[]){inti=0;booleanboo=true;intlength=3000;while(boo){if(length
题目详情
假设有一条绳子长3000m,每天减去一半
public class chapter337 {
public static void main(String args[])
{
int i=0;
boolean boo=true;
int length=3000;
while(boo)
{
if(length
public class chapter337 {
public static void main(String args[])
{
int i=0;
boolean boo=true;
int length=3000;
while(boo)
{
if(length
▼优质解答
答案和解析
public static void main(String args[]) {
int i = 0;
boolean boo = true;
int length = 3000;
while (boo) {
if (length < 5) {
boo = false;
}
int len2 = length - length / 2;
length = len2;
i++;
}
System.out.print(i + "天后绳子小于5M");
}
}
多了一组括号
class chapter337 {public static void main(String args[]) {
int i = 0;
boolean boo = true;
int length = 3000;
while (boo) {
if (length < 5) {
boo = false;
}
int len2 = length - length / 2;
length = len2;
i++;
}
System.out.print(i + "天后绳子小于5M");
}
}
看了 假设有一条绳子长3000m,...的网友还看了以下:
真正挑战高智商 因事分解设常系数多项式p(x)=x^4+ax^3+bx^2+cx+d满足:p(1) 2020-05-13 …
若有以下定义,则值为4的表达式是 A)p+=3,*(p++) B)p+=3,*++p C)p+=4 2020-05-13 …
如图,抛物线y=ax2+bx+c(a≠0)过点(-1,0)和点(0,-3),且顶点在第四象限,设P 2020-05-17 …
三相功率P=根号3*U*I*COSφ=660*U*I*COSφ,单相p=U*I*COSφ=220* 2020-07-19 …
指针问题设intx[]={1,2,3,4,5,6},*p=x;则数值为3的表达式是(B)。(A)p 2020-07-30 …
A(1,3).B(-3,1).C(-1,-4).D(5,-2).P(3,4)为平面直角坐标系内五个 2020-07-31 …
判断下列各对直线是否垂直:(1)y=x,2x+2y-7=0(2)x+4y-5=0,4x-3y-5= 2020-08-01 …
集合M={p*p,-3,1+p}.N={p*p+1,p-3,2p-1},M交N={-3}.其中p属 2020-08-02 …
(*p)[3]在里面是什么意思,另外定义一个数组吗*题9.66C若有以下定义和语句,则对a数组元素 2020-08-03 …
用逻辑联结词“且”、“或”联结命题p,q,并判断复合命题“p且q”、“p或q”的真假:1、p:6是3 2020-12-07 …