Codejam Qualification Round 2022. Task 1
Python Only
T=int(input())
for t in range(T):
N=input()
print('Case #{}:'.format(t+1))
[R,C]=[int(n) for n in N.split()]
str1='..+-+'+(C-2)*'-+'
str2='..|.|'+(C-2)*'.|'
str3='+-+-+'+(C-2)*'-+'
str4='|.|.|'+(C-2)*'.|'
[print(el) for el in [str1,str2,str3,str4,str3]]
for i in range(R-2):
print(str4)
print(str3)
No comments:
Post a Comment