Pergunta de entrevista da empresa SWIFT

Write a function that counts the letters of a string and record them

Resposta da entrevista

Sigiloso

15 de dez. de 2022

txt = "apple" myDict = {} for x in txt: myDict[x] = txt.count(x)