Here I am showing couple of examples to comment several line at once using vim editor.
I have a text file with 15 line in it.
To comment from line number 5 to 10:
To comment 5 lines after line number 5 and including line number 5:
To comment all lines: