백준 25088번: Punched Cards #Python

ColorlessDia·2025년 10월 10일

algorithm/baekjoon

목록 보기
691/807
import sys

input = sys.stdin.readline

T = int(input())

for t in range(1, T + 1):
    R, C = map(int, input().split())
    c = C - 1

    print(f'Case #{t}:')

    print(f'..+{'-+' * c}')
    print(f'..|{'.|' * c}')
    print(f'+-+{'-+' * c}')

    for _ in range(R - 1):
        print(f'|.|{'.|' * c}')
        print(f'+-+{'-+' * c}')

0개의 댓글