Living in the Shell #21; head (Display File Content From Beginning)

head ๐
Displays file content from beginning.
Print first N lines of a file -n
head -n 5 ~/.bashrc
Print all but N last lines -n -N
tail -n -3 ~/.bashrc
Print first N bytes of a file -c
head -c 1k ~/.bashrc
Prints first 1k of file binary content.
Print all but N last bytes -c -N
tail -c -1k ~/.bashrc
![Godoc-Lint: a linter for Go Doc Comments (godocs) [RE#16]](/_next/image?url=https%3A%2F%2Fcdn.hashnode.com%2Fres%2Fhashnode%2Fimage%2Fupload%2Fv1741533596295%2F731ef95a-1af8-49ae-843d-a19d9d418fdf.png&w=3840&q=75)
![Optimize Postgres Containers for Testing [RE#15]](/_next/image?url=https%3A%2F%2Fcdn.hashnode.com%2Fres%2Fhashnode%2Fimage%2Fupload%2Fv1741533395875%2Fe1a3c4fc-4354-4482-88b8-e8c14750e00a.png&w=3840&q=75)

