يعطيكم العافية...
كتبت هذا الكود:
with open(f, 'rb') as myfile:
text = [s.strip() \
for s in myfile.readlines()]
for t in text:
x = t.strip().lower()
if 'text' in x:
continue
لكن عند التنفيذ يعطيني خطأ في السطر الاخير:
TypeError: a bytes-like object is required, not 'str'