下列代码中哪行有错误?publicclassTest{publicstaticvoidmain(Stringargs[]){charc='a';byteb=128;intheight=100;floatf=3.14F;}}
A. charc='a';
B. byteb=128;
C. intheight=100;
D. floatf=3.14F;
查看答案
下列代码中哪行有错误?publicclassTest{publicstaticvoidmain(Stringargs[]){charc=65536;byteb=127;intheight=100;floatf=3.14F;}}
A. charc=65536;
B. byteb=127;
C. intheight=100;
D. floatf=3.14F;
下列代码中哪行有错误?publicclassTest{publicstaticvoidmain(Stringargs[]){int x=8;byteb=127;b=x;x='a';long y=b;float z=(int)6.89;}}
A. b=x;
B. x='a';
C. long y=b;
D. float z=(int)6.89;
下列代码中哪行有错误?publicclassTest{publicstaticvoidmain(Stringargs[]){char c=65535;byteb=127;int height=100;float f=3.14;}}
A. char c=65535;
B. byteb=127;
C. int height=100;
D. float f=3.14;
下列代码中哪行有错误?publicclassTest{publicstaticvoidmain(Stringargs[]){int m='a';unsigned char x='m';char ch=97;double t=0.1;}}
A. int m='a';
B. unsigned char x='m';
C. char ch=97;
D. double t=0.1;