Python Wstaw tekst do ciągu przed pewnym symbolem
my_str = "thisissometextthatiwrote"
substr = "text"
inserttxt = "XX"
idx = my_str.index(substr)
my_str = my_str[:idx] + inserttxt + my_str[idx:]
Fragile Finch