https://school.programmers.co.kr/learn/courses/30/lessons/120884
git 바로가기
def solution(chicken):
answer = 0
while chicken >= 10:
div = chicken // 10
mod = chicken % 10
answer += div
chicken = div+mod
return answer
def solution(chicken):
answer = 0
while chicken >= 10:
div, mod = divmod(chicken, 10)
answer += div
chicken = div+mod
return answer
https://velog.io/@jsanga214/%EC%BD%94%ED%85%8C%EC%A4%80%EB%B9%84-math