国开在线答案
-
2022-09-12
[判断] 向量类Vector中的size()方法能够返回向量中当前保存的元素的个数。
-
2022-09-12
[判断] 向量类Vector中的get(i)方法不能够返回向量中下标为i的元素值。
-
2022-09-12
[判断] 向量类Vector中的set(i,x)方法不能够把向量中下标为i的元素值修改为x的值。
-
2022-09-12
[单选] 下列能表示栈(stack)s1长度的是( )。
-
2022-09-12
[单选] 下面的关键字( )与异常处理无关。
-
2022-09-12
[单选] Public class Test {
Public static void main(String[] args) {
Vector teamList = new Vector();
teamList.add("Z");
teamList.add("L");
teamList.add("W");
teamList.remove(0);
teamList.remove(0);
System.out.println(teamList.size()+","+teamList.get(0));
}
}
-
2022-09-12
[单选] public class XXK4 {
public static void main(String[] args) {
int [][]a={{2,5,8},{3,6,9},{4,5,6}};
int []b=new int[3];
int i,j;
for(i=0; i<a.length; i++)
for(j=0; j<a[i].length; j++)
b[i]+=a[i][j];
for(i=0; i<b.length; i++)
System.out.print(b[i]+" ");
}
}
-
2022-09-12
[单选] class ABC {
String name;
double price;
public ABC(String na, double pr) {name=na; price=pr;}
public int compareTo(ABC x) {
if(name.compareTo(x.name)>0) return 1;
if(name.compareTo(x.name)<0) return -1;
else return 0;
}
}
public class XXK5 {
public static void main(String[] args) {
String []s={"apple", "pear", "tangerme", "banana", "grape"};
double []d={3.8, 2.5, 3.2, 4.3, 5.2};
ABC []ar=new ABC[s.length];
int i,k=0;
for(i=0; i<ar.length; i++)
ar[i]=new ABC(s[i],d[i]);
for(i=1; i<ar.length; i++)
if(ar[i].compareTo(ar[k])>0) k=i;
System.out.println(ar[k].name+" "+ar[k].price);
}
}
-
2022-09-12
[单选] 【单项选择题】税收权利主体是( )。
-
2022-09-12
[单选] 【单项选择题】下列不属于流转税类的是( )。
- 首页
- 上一页
-
6851
-
6852
-
6853
-
6854
-
6855
-
6856
-
6857
-
6858
- 下一页
- 尾页