I would like to know how I can read a text file that has lines of 1's, 2's, and 0's going two characters at a time.
For example, a line may look like
2 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2
and then making each '1 1' as 0, either '1 2' or '2 1' as 1, and '2 2' as 2, and then any pair with a 0 in it as -1 (ie '0 1')
I have tried the search and replace function, but that does not do so well with going by 2 characters at a time per line, so it all messes up.
Thank you