I waste a lot of time between Vim and Python. I find it too slow to manually copy-paste from Python to Vim and vice versa. A good broken example is:
%
If I want to print 'Hello' to lines 4,5, 6 and 7, what is wrong:
If you want to do something in randomly chosen places throughout your file, you're better of recording keystrokes and replaying them. Go to the first line you want to change, and hit qz
to starting recording into register z
. Do whatever edits you want for that line and hit q
again when you're finished. Go to the next line you want to change and press @z
to replay the macro.