[Python] 백준 33675번: L-트로미노 타일링
https://www.acmicpc.net/problem/33675 [풀이]타일의 세로 길이는 무조건 3가로 길이가 2의 배수여야 각각 2개의 방법씩 대입할 수 있다. 가로의 길이가 N이라면,짝수인 경우, 해당 방법은 2 * (N // 2)만큼 나올 수 있다.홀수인 경우, 0개이다. (빈 공간이 발생하기 때문) [코드]import sysinput = lambda: sys.stdin.readline().rstrip()result = []for _ in range(int(input())): n = int(input()) x = int(2 ** (n / 2)) if n % 2 == 0: result.append(str(x)) else: result.appe..
CS/Algorithm
2025. 8. 30.