Hello,
I searched online; it seems that perl use $NR as NR in awk; however it does not work for me. For example, how to re-write the following awk using perl:
awk '{ print NR}' inputfile
---------- Post updated at 01:55 PM ---------- Previous update was at 12:49 PM ----------
I found following perl command will work the same as awk:
perl -MEnglish -lane 'print $NR' inputfile
However, I am wondering, if i am writing a perl script, is there a simple way to denote NR (number of record)?