I wrote this code:
#! /usr/bin/python
# -*- coding: utf-8 -*-
with open("pdb.txt", "r+") as pdb_file, open("pdpbe.txt", "r+") as e_file:
breakpoint()
pdb_file=pdb_file.readlines()
e_file=e_file.readlines()
breakpoint()
for line, eline in zip(pdb_file, e_file):
line=line.strip()
eline=eline.strip()
breakpoint()
if line==eline:
print(line)
breakpoint()
I got following error:
SyntaxError: unexpected EOF while parsing" before pdb_file=pdb_file.readlines().
My text files look fine. Could someone help me, please? I am using Python 3.7.9.