Hi Buran
I am having a similar issue to the above.
The below is my code, but my dictionary isn't including the word which has punctuation in at all, I attempted to follow your advice but no success, any more hints?
I am having a similar issue to the above.
The below is my code, but my dictionary isn't including the word which has punctuation in at all, I attempted to follow your advice but no success, any more hints?
def myfunction(cadena): texto=cadena x=texto.lower().split() Dict={} for element in x: if element.isalpha(): if element in Dict: Dict[element]+=1 else: Dict[element]=1 else: element[:-1] return(Dict) print(myfunction("Hola que haces? Por favor respondeme, di hola por lo menos!"))