text = "hi, hello! hello! I have a cat hello! the fire burns 88988° the planes are sooo fast" #Exmple string
print(len(text))
if(len(text) > 20):
#text = text[:-10]
t_len = len(text) +(-len(text) - 10)
text = text[:-t_len]
print(len(text))
print(text)
I was trying with several things but what I need is that if len (string)> n then extract me and save the last 50 characters in another variable