VIM: find empty lines and print them with 1,2,3 lines after and before

Viewed 1497

I can find empty lines doing this command :g/^$. How to extend this command to print 1 line (2 lines, etc.) before exact empty line and after?

2 Answers
Related