Question: 1-Write a script in Python that delete all data discrepancies from a file as follows. The next 2 entries need to be discarded because the

1-Write a script in Python that delete all data discrepancies from a file as follows.

The next 2 entries need to be discarded because the session ID and the 4th character of the exercise ID do not match as illustrated in the next 2 lines.

4, 91, Es_5_2, TextEditor_Es_5_2, 13.11.2014 11:37:41, 13.11.2014 11:37:53, 27673, 6, 0, 2, 0, 252, 0

4, 91, Es_5_2, Other, 13.11.2014 11:37:54, 13.11.2014 11:37:59, 343, 0, 0, 4, 0, 171, 0

The next entry need NoT be discarded.

4, 91, Es_4_4, Blank, 13.11.2014 11:37:39, 13.11.2014 11:37:39, 0, 0, 0, 0, 0, 0, 0

- Note that the file contains hundreds of lines and these are only examples.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!