5、下列程序的运行结果是()。public class Test {public static void test() {this.print();}public static void print() {System.out.println("Test");}public static void main(String args []) {test();}}
A. 输出Test
B. 无输出结果
C. 编译错误,指示不能在static上下文中使用this
D. 以上都不对
查看答案
6、在Java中,以下程序编译运行后的输出结果为()。public class Test {int x, y;Test(int x, int y) {this.x = x;this.y = y;}public static void main(String[] args) {Test pt1, pt2;pt1 = new Test(3, 3);pt2 = new Test(4, 4);System.out.print(pt1.x + pt2.x);}}
A. 7
B. 6
C. 3 4
D. 8
7、下列程序的运行结果是()。public class Test {private String name;Test(String name){this.name = name;}private static void show(){System.out.println(name) ;}public static void main(String[] args){Test d = new Test("lisa");d.show();}}
A. 输出lisa
B. 输出null
C. 输出name
D. 编译失败,无法从静态上下文中引用非静态变量name
利率互换的合理用途不包括()
A. 降低融资成本
B. 对冲利率风险
C. 构造产品组合
D. 对冲汇率风险
交易双方约定在未来的某一确定时间,以确定的价格买入或卖出一定数量的某种金融资产的合约是()
A. 期权
B. 互换
C. 远期
D. 股票