Algorithm
2023. 12. 12.
[파이썬] 백준 1072번: 게임
https://www.acmicpc.net/problem/1072 1072번: 게임 김형택은 지금 몰래 Spider Solitaire(스파이더 카드놀이)를 하고 있다. 형택이는 이 게임을 이길 때도 있었지만, 질 때도 있었다. 누군가의 시선이 느껴진 형택이는 게임을 중단하고 코딩을 하기 시 www.acmicpc.net x, y = map(int, input().split()) z = int(y*100/x) def solution(x, y, z): left = 1 right = 10**9 if z == 100 or z == 99: return -1 while left z: right = mid - 1 else: left = mid + 1 return left print(solution(x, y, z)) 이..