310-025精选题(31)的具体内容如下:' P5 z: J+ e2 a2 |
110. Consider the code fragment below:
4 K6 q( y# o" _# a( D# Louter: for(int i = 0; i < 2; i++){' \" \, t5 ~5 A7 f% Q- x
inner: for(int j = 0; j < 2; j++){
7 o# [) g, ?- m# z& M2 c6 P4 w9 Iif(j==1)
) o3 z% q$ n) K1 S# B/ S8 Zcontinue outer; {$ |& v9 i' H1 O% x- ]
System.out.println("i = " + i ", j = " + j);
9 ^# ^* O0 _* |; c7 z& _}}/ p1 C% G0 x: _& n5 a
Which of the following will be printed to standard output?
) H7 m/ U! [% \' ?7 X) {A. i = 0, j = 0
$ d6 e6 K1 {; y' rB. i = 1, j = 0
- h# P2 x# R4 u7 l5 yC. i = 2, j = 0
; Y5 R: C6 Z$ @% S/ J" w7 ED. i = 0, j = 14 e' t* t/ b! X* g
E. i = 1, j = 1
0 P) ?% G+ e6 o9 e% ]$ u; G9 e3 xF. i = 2, j = 1
" B6 P+ ? z/ w/ X" R+ l' L. Y7 ]% \1 {* ~G. i = 0, j = 2
A) V2 c1 z2 l1 n5 qH. i = 1, j = 21 _" d8 Y; E U$ j9 Z7 E% z8 ]" h
I. i = 2, j = 2, H" p1 I! w: t4 T4 m* ^, R" }+ G# b9 R
AB.4 x9 F# N4 D; L
111. Consider the code fragment below:- G( P' N+ b: I1 i$ A1 ?
outer: for(int i = 1; i < 3; i++){) R. r1 Z9 f3 @
inner: for(int j = 1; j < 3; j++){
' }# K3 s7 ?$ [9 J4 aif(j==2)
8 Y4 h: J4 k# O; x! Zcontinue outer;
, J& S# @& ], N% G1 l. M$ VSystem.out.println("i = " + i ", j = " + j);
+ `4 T8 {% m" c}}& z' V# q6 H) R2 O4 D
Which of the following will be printed to standard output?
& X! i6 T! o: K* f" {A. i = 1, j = 1
1 g& {8 a% d: H4 g9 }2 LB. i = 1, j = 2
, W# @8 _7 V5 i) |, i( N9 lC. i = 1, j = 30 Y1 i& m8 E8 V2 n w8 q1 |
D. i = 2, j = 1
" K# ]3 k* c/ p' f& Y- t' I/ RE. i = 2, j = 20 b+ u! H6 P G$ T B" ^
F. i = 2, j = 3
O& X3 Y+ D9 K# C2 }' n( TG. i = 3, j = 1
\+ b8 @ E/ }" A, XH. i = 3, j = 2
+ q8 o% _7 R" l3 q, e& _; nAD. |