</p> Q132 What is the possible output of the following program?
; L/ x8 a* h5 o+ ~6 ~ import java.util.*;8 D G' @( X6 T9 W: Q& S
class Question {1 \) @; Y% E$ p5 Z+ e
public static void main (String args[])
9 ~; S$ l, y' `5 C {
, ]; Q5 [. p& [. j' _ HashSet set = new HashSet();
, Z, E$ O( w' G String s1 = “abc”;8 K( @: `: G) Y; y6 [
String s2 = “def”;) S' c% r0 {5 k4 ~. c! f N" F
String s3 = “”;
' g E) R8 u6 M8 H* b2 ?4 J: d set.add(s1);4 ^& D- T9 P8 V5 T) }
set.add(s2);6 R8 t5 z n! C9 s
set.add(s1);
) h G" i t, V# q set.add(s2);7 G1 |; o) v. u. b
Iterator i = set.iterator();# H% Z8 V7 N" [1 Q- v
while(i.hasNext()) {
1 z: d+ i! n; |2 S s3 += (String) i.next();/ g2 p. i- `! Z$ O/ u, k
}7 _6 C$ j, R) W( A& j/ }6 H
System.out.println(s3);
# ~; Y0 P, ]7 t5 h" z6 G* \6 K } }6 U' M( x8 q$ G% z
}
3 \6 v) y& K0 T8 w8 @( u w; b A abcdefabcdef. Y# _) a* F/ J" l2 `
B defabcdefabc
5 V: K/ Q0 T! i5 F+ [, w C fedcbafedcba4 ^$ b A. ~% ?4 l" ?& _3 \& G5 ?
D defabc
& {; N0 l( o, C4 L0 m3 R7 l Q130 C. v. c' p, {) Q [
Q131 B% T! b1 B" U# q& ?9 i- b- x
Q132 D |