https://www.fosslinux.com/105301/how-to-write-efficient-bash-scripts-with-control-structures.htm
How to write efficient Bash scripts with control structures