PRO192_-_SP_2024_-_Block_5_-_FE_1921.webp
K

PRO192_-_SP_2024_-_Block_5_-_FE_1921.webp

Multiple Choices
}
}
(Choose 1 answer)
What is the output when the program below is run?
public class Test{
public static void main(String[] args){
String s1 = "xyz";
String s2 = new String(s1);
if (s1 == s2)
System.out.println("Line 4");
if (s1.equals(s2))System.out.println("Line 6");
What is the output?
A. Line 4
B. Line 6
C. Line 4 Line 6
D. No output, compile error
E. No output

Thông tin

Category
PRO192
Thêm bởi
Kurourushi89
Ngày thêm
Lượt xem
4,810
Lượt bình luận
23
Rating
0.00 star(s) 0 đánh giá

Share this media

Back
Bên trên Bottom