> For the complete documentation index, see [llms.txt](https://www.techwithtyler.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://www.techwithtyler.dev/coding-and-cli-tooling/coding-and-scripting/bash.md).

# Bash

{% code lineNumbers="true" %}

```bash
# for loop
root@box ~ $ for num in {1..4}; do echo "The number is: $num"; done
The number is: 1
The number is: 2
The number is: 3
The number is: 4
```

{% endcode %}

```bash
# for loop combining awk
root@box ~ $ for subd in $(awk '{print $1 ""}' subdomains.txt); do echo $subd; done
blog.techwithtyler.dev
braindump.techwithtyler.dev
techwithtyler.dev
www.techwithtyler.dev

# original file
root@box ~ $ cat subdomains.txt
blog.techwithtyler.dev 234234234
braindump.techwithtyler.dev 25346536
techwithtyler.dev 43564356743
www.techwithtyler.dev 45776568
```
