PRO192_-_SU_2024_-_Block_5_-_FE_2618.webp
Quốc Hùng2

PRO192_-_SU_2024_-_Block_5_-_FE_2618.webp

Kizspy | Question: 34
(Choose 1 answer)
What is the output of the following code snippet?
public class Program {
void swap(Integer 11, Integer t2){
int temp =t1;t1=t2;
t2=temp;
}
void f1(){
List<Integer> list = new ArrayList();
list.add(1);list.add(2);
swap(list.get(0), list.get(1));
System.out.println(list);
FUOVER
}
public static void main(String[] args) {
}
new Program().f1();
}
A. [1, 2]
B. [2, 1]
C. [1, 1]
D. [2, 2]

Thông tin

Category
PRO192
Thêm bởi
Quốc Hùng2
Ngày thêm
Lượt xem
2,956
Lượt bình luận
13
Rating
0.00 star(s) 0 đánh giá

Share this media

Back
Bên trên Bottom