Language/Python

[Python / 프로그래머스 level 1] 핸드폰 번호 가리기

ej503 2021. 6. 17. 00:30

def solution(x):
    for i in range(len(x)-4):
        x= x.replace(x[i], "*", 1)
    return x