> For the complete documentation index, see [llms.txt](https://thamizhiniyancs.gitbook.io/writeups/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://thamizhiniyancs.gitbook.io/writeups/hackerrank/linux-shell/text-processing/tail.md).

# Tail

## Tail of a Text File #1

In this challenge, we practice using the *tail* command to display the last n lines of a text file.

Display the last 20 lines of an input file.

```bash
tail -n 20
```

***

## Tail of a Text File #2

In this challenge, we practice using the *tail* command to display the last 20 characters of a text file.

Display the last 20 characters of an input file.

```bash
tail -c 20
```
