Jun-18-2020, 06:50 AM
Hi,
What i would do is read all of the file2 identifiers into a list (using append).
You will end up with something like identif = ['1111', '2222','3333',...]
Close file2.
Now you read file1 line per line and iterate over ident[...] to look for a match.
It is not clear to me from your data, if 2 lines below there is another identifier match,
or what is is you want to do next.
Paul
What i would do is read all of the file2 identifiers into a list (using append).
You will end up with something like identif = ['1111', '2222','3333',...]
Close file2.
Now you read file1 line per line and iterate over ident[...] to look for a match.
It is not clear to me from your data, if 2 lines below there is another identifier match,
or what is is you want to do next.
Paul
It is more important to do the right thing, than to do the thing right.(P.Drucker)
Better is the enemy of good. (Montesquieu) = French version for 'kiss'.
Better is the enemy of good. (Montesquieu) = French version for 'kiss'.