PRO192_-_FA_2024_-_FE_2969.webp
B

PRO192_-_FA_2024_-_FE_2969.webp

Kizspy | Question: 44 (Choose 1 answer)
FUOVERFL
What is the output of the following code snippet?Map<Character, Integer> map = new TreeMap();
String data = "hello";
for (Character c: data.toCharArray()) {
if (map.containsKey(c)) { map.put(c, map.get(c) + 1);
} else { map.put(c, 0);
}
}
System.out.println(map.keySet());
A. ['e', 'h','l','o']
B. ['h','o','e','l']
C. ['e','o', 'h','l']
D. ['h','e','l','o']

Thông tin

Category
PRO192
Thêm bởi
Bích Thủy
Ngày thêm
Lượt xem
4,498
Lượt bình luận
7
Rating
0.00 star(s) 0 đánh giá

Share this media

Back
Bên trên Bottom