Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 1 1 5
- 1 2 4
- 1 4 2
- 2 1 5
- 2 2 6
- 2 3 5
- 1 1 5
- 1 2 4
- 1 3 0
- 1 4 2
- 1 5 0
- 2 1 5
- 2 2 6
- 2 3 5
- 2 4 0
- 2 5 0
- with open('test.sum') as f:
- check = 0
- for line in f:
- if int(line.split()[1]) == check + 1:
- check = int(line.split()[1])
- print line.rstrip()
- else:
- check = int(line.split()[1])
- print int(line.split()[1]) - 1, 't0'
- print line.rstrip()
- print int(line.split()[1]) + 1, 't0'
- print int(line.split()[1]) + 2, 't0'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement