Algorithm Study/BOJ with python2 [백준] 2438번: 별 찍기 - 1 2438번: 별 찍기 - 1 첫째 줄에는 별 1개, 둘째 줄에는 별 2개, N번째 줄에는 별 N개를 찍는 문제 www.acmicpc.net 1 2 3 4 input_data = input().split(' ') a = int(input_data[0]) for num in range(1, a+1): print('*'*num) 파이썬의 강점 중 하나라고 할 수 있네요 '*'*num 그리고 파이썬은 print 안에 조건문을 또 넣어서 사용할 수 있는거 같네됴 파이썬의 세계.....정복하리 2020. 7. 25. [백준] 1330번: 두 수 비교하기 https://www.acmicpc.net/problem/1330 1330번: 두 수 비교하기 두 정수 A와 B가 주어졌을 때, A와 B를 비교하는 프로그램을 작성하시오. www.acmicpc.net 두 수를 비교하는 아주 쉬운 문제 입니다. 1 2 3 4 5 6 7 8 9 10 input_data = input().split(' ') a = int(input_data[0]) b = int(input_data[1]) if a > b: print('>') elif a 2020. 7. 24. 이전 1 다음