</p> 5. }
/ O( E9 ~- V) a. m# b" h Select the one right answer.
; `2 ^% b3 d; l a. The code won't compile. The compiler will complain about the expression 0x10 + 10 + 010# V, N, Z- m a1 g4 [, l- W
b. When run, the program will print “28”
9 r2 G. t: h, E* b0 c, q& D7 n( I c. When run, the program will print “34”
+ s+ M7 V4 h- R8 _2 ` d. When run, the program will print “36”
+ q- L/ h' G7 }; x# j Q66.How will the following program lay out its buttons? M9 \. m* h% Q# h/ `
1. import java.awt.*;( V$ y& c4 y6 @" _" |4 L# ^
2. public class MyClass {
2 D/ }: u1 I- M. K5 ~ 3. public static void main(String args[]) {( K8 K: m" C7 S
4. String labels[] = {”A”,”B”,”C”,”D”,”E”,”F”};
. U/ M9 e# \& {# V# ] w" [/ D! n 5. Window grid = new Frame();. v; p7 X& Z5 j6 ~
6. grid.setLayout(new GridLayout(0,1,2,3));
0 A3 i" e& ^! L; x$ O9 Q1 `4 H) g4 e 7. for(int i=0;i$ A0 n2 C# U+ b% |" ?3 {
8. grid.add(new Button(labels));
7 W4 N, t; {2 N9 I 9. }0 z" F% s5 i: X' J, \9 ^
10. grid.pack();# [+ B! N4 s# ^: }! Y) W/ I+ ]8 a
11. grid.setVisible(true);1 _4 x: b% a+ O4 y: a
12. }% W/ @; L# g- g' x0 O3 A# ~* E1 L
Select the one right answer
1 e I# r& T/ `+ v, {9 W a. The program will not show any buttons at all.
F1 [' ?; f$ W0 L b. It will place all buttons in one row - A B C D E F.
$ ]% n) {2 b5 n" h/ L( p6 N1 N c. It will place all buttons in one column, i.e., each button in a separate row - A B C D E and F.
9 B* V, n# l& Y& K- ~
' T b. R' x/ k3 x* F! n6 X" j d. It will place pairs of buttons in three separate row A B, C D and E F./ s5 I. O/ N) _0 M: ]& y* ?8 y
64. a& t* B( t" J# Q7 @, e8 T9 I+ l2 V
65. c0 J( v6 w/ ]- `1 v5 ^7 {
66. c |