본문 바로가기

Programming [Python]/백준 알고리즘 솔루션

#264 백준 파이썬 [10995] 별 찍기 - 20

https://www.acmicpc.net/problem/10995

 

Python Code

N = int(input())

if N == 1:
    print('*')
    
else:
    for n in range(N):
        if n % 2 == 0:
            a = print('* ' * N)
        else:
            b = print(' *' * N)