Untitled
plain_text
2 months ago
543 B
1
Indexable
Never
tiket = int(input("masukkan nomor tiket : ")) # 1 : 4 = kolom # 1, 2, 3 ketiganya kalau // 4 = 0 --> baris 1 # 5, 6, 7 ketigany kalau // 4 = 1 --> baris 2 # 9, 10, 11 ketiganya kalau // 4 = 2 --> barois 3 kolom = tiket % 4 if kolom == 0: kolom = 'D' elif kolom == 1: kolom = 'A' elif kolom == 2: kolom = 'B' elif kolom == 3: kolom = 'C' elif kolom == 4: kolom = 'D' baris = tiket // 4 if kolom != 0: baris = baris + 1 print(f"Tempat duduk tiket nomor : {baris}{kolom}") #print(f"Tempat duduk tiket nomor : ")