in reply to Re: File Handle Basics
in thread File Handle Basics

You want -p for the impicit loop and print, instead of -n wich just loops.

Also, since I've picked up Golf recently...

perl -i -lpe'/^%/?--$.:s/^(?:N\d+\s?)?/N$. /'

— Arien