Untitled

user_5668965 avatar
user_5668965
c_cpp
07/20/2024 8:48 AM
312 B
25
Indexable
for _ in range(int(input())):
    s = input()
    for c in "abcdefgh":
        if c != s[0]:
            print(c + s[1], end=' ')
    for c in "12345678":
        if c != s[1]:
            print(s[0] + c, end=' ')
    print()
Editor is loading...
Leave a Comment