본문 바로가기
프로그래밍 문제/[Python] CheckIO

[CheckIO/Electronic Station] digits-multiplication

by Physics 2024. 4. 7.
728x90

1. Problem: https://py.checkio.org/en/mission/digits-multiplication/
2. My solution:

def checkio(number: int) -> int:
    # your code here
    dummy = 1;
    for number in list(str(number)):
        if int(number) != 0: dummy *=int(number)
    return dummy
728x90

댓글