x = True y = False z = False if not x or y: print(1) elif not x or not y and z: print(2) elif not x or y or not y and x: print(3) else : print(4) Kết quả nào là output của đoạn code dưới đây?

x = True

y = False

z = False

if not x or y:

print(1)

elif not x or not y and z:

print(2)

elif not x or y or not y and x:

print(3)

else :

print(4)

Kết quả nào là output của đoạn code dưới đây?

A. 2

B. None

C. 1

D. 3

Hướng dẫn

Chọn D là đáp án đúng

 

Thư viện tài liệu12 Tháng bảy, 2023 @ 2:28 chiều

Đánh giá chủ đề này