nl

A command that prints a file with numbered lines.

In more detail

By default it numbers only non-empty lines; nl -b a numbers every line. cat -n does a similar job.

Taught in

References

Certification courses