单项选择题

以下程序输出结果为( )。
class test 2
public static void main(String args[])

int n=7;
n<<=3;
n=n&n+1 |n+2^n+3;
n>>=2;
System.out.println(n);

A.0
B.-1
C.14
D.64
<上一题 目录 下一题>
热门 试题

单项选择题
有如下程序; public class MethTest static int Varl=100; int Var2=200; public static void main(String args[]) Varl=10; MethTest Obj1=new MethTest(); MethTest Obj2=new MethTest(); Obj1.Varl++; System.out.println(Objl.Varl); Obj2.Varl++; System.out.println(Obj2.Varl); MethTest.Varl++; System.out.println(Objl.Varl); Obj1.Var2++; System.out.println(Obj1.Var2); Obj2.Var2++; System.out.println(Obj2.Var2); 程序的运行结果为( )。
A.11
12
13
201
201
B.101
102
103
201
201
C.11
12
13
201
202
D.10
10
10
201
201
单项选择题
下列程序运行后的输出结果是( )。 public class Sun public static void main(String args[]) int a,b; a=0; b=0; for(int m=1;m<=10;m++) a=a+1; b=0; for(int j=1;j<=10;j++) a=a+1; b=b+2; System.out.println(a+ , +b);
A.10,20
B.20,110
C.110,20
D.200,110
相关试题
  • 下面程序输出的结果是什么 ( ) public...