I am trying to cut my string from "<em class=\"txt\">" to </em">.
type = line[line.find("<em class=\"txt\">")+16:line.find(line.find("</em>"),line.find("<em class=\"txt\">"))]
And this is error:
TypeError: Can't convert 'int' object to str implicitly
I sure there's something wrong with adding int in this code. But why it want to convert int to str? I want to add int to result of line.find() so also to int. It should work properly.
Generally I want to achieve this:
Input:
<em class="txt">blablabla</em>
Output:
blablabla