I am trying to find out if there is a way to split the value of each iteration of a list comprehension only once but use it twice in the output.
As an example of th
You could use a list comprehension wrapped around a generator expression:
[(x[1],x[2]) for x in (x.split(";") for x in a.split("\n")) if x[1] != 5]