while True : #infinite iteration, A = input ( "Enter A" ), B = input (" Enter B" ), if A == "1" and B=="1" :, print ( " 1" ) # out 1 to the screen, else: # the code underneath is executed when the if condition is false, print ( " 0 " ) # out 0 to the screen, repeat = input ( " repeat? Y/N" ), if repeat == " Y" :, continue # this ensures the algorithm loops back, else : # the code underneath is executed when the if condition is false, break # this statement breaks from the loop

Logic Gate Code....

Phong cách trực quan

Hiển thị tất cả

Cài đặt hoạt động

Bảng xếp hạng

Chuyển đổi mẫu

Bạn có muốn khôi phục tự động lưu: không?