1
0
Fork 0
This commit is contained in:
wagner.agnieszka 2018-06-01 19:28:21 +02:00
parent 96214d2d3f
commit bac748992f
1 changed files with 9 additions and 4 deletions

View File

@ -9,10 +9,15 @@ Np. leet('leet') powinno zwrócić '1337'.
def leet_speak(text):
for i in text :
if i == "e" :
if 'e' in text :
text = text.replace("e", "3")
if "l" in text :
text = text.replace("l", "1")
if "o" in text :
text = text.replace("o", "0")
if "t" in text :
text = text.replace("t", "7")
return(text)
def tests(f):
inputs = [['leet'], ['do not want']]