본문 바로가기

BOJ/Python

[BOJ/백준] 32314 - Christmas Tree Adapter (Python)

문제 링크

변압기의 암페어가 트리의 암페어보다 크거나 같은지 판단하는 문제이다.

 

변압기의 암페어 = w/v이다. 계산한 값과 a(트리의 암페어)를 비교하면 된다.

a=int(input())
w,v=map(int, input().split())

if a<=w/v:
    print(1)
else:
    print(0)