simeonshopov

Building

Oct 21st, 2019
243
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.26 KB | None | 0 0
  1. floors = int(input())
  2. rooms = int(input())
  3.  
  4. for i in range(floors, 0, -1):
  5.   for j in range(rooms):
  6.     if i == floors:
  7.       print(f" L{i}{j}", end="")
  8.     elif i % 2 == 0:
  9.       print(f" O{i}{j}", end="")
  10.     else:
  11.       print(f" A{i}{j}", end="")
  12.   print()
Advertisement
Add Comment
Please, Sign In to add comment