Repetitive tasks

Chapter 9. Repetitive tasks

Table of Contents
9.1. The for loop
9.1.1. How does it work?
9.1.2. Examples
9.2. The while loop
9.2.1. What is it?
9.2.2. Examples
9.3. The until loop
9.3.1. What is it?
9.3.2. Example
9.4. I/O redirection and loops
9.4.1. Input redirection
9.4.2. Output redirection
9.5. Break and continue
9.5.1. The break built-in
9.5.2. The continue built-in
9.5.3. Examples
9.6. Making menus with the select built-in
9.6.1. General
9.6.2. Submenus
9.7. The shift built-in
9.7.1. What does it do?
9.7.2. Examples
9.8. Summary
9.9. Exercises

Upon completion of this chapter, you will be able to

  • Use for, while and until loops, and decide which loop fits which occasion.

  • Use the break and continue Bash built-ins.

  • Write scripts using the select statement.

  • Write scripts that take a variable number of arguments.


134 visits (1 today, 11 this week, 49 this month, 134 this year)
Uptime: 19:37:30 up 10 days, 1:20, 8 users, load average: 0.06, 0.06, 2.75
18.216.156.226 GET from server z.larryforalaska.com

Friday, December 27, 2024 @ 7:37:30 PM
z.ServerAdmin@lam1.us