July 2018
Beginner
264 pages
8h 9m
English
So far in the book, we have mentioned that function is a reserved word and only used in Bash scripts that are in a single procedure, but what is a function?
To illustrate what a function is, first we need to define what a function is—a function is a self-contained section of code that performs a single task. However, a function performing a task may also execute many subtasks in order to complete its main task.
For example, you could have a function called file_creator that performs the following tasks:
A function can also be passed parameters. Parameters are like variables that ...
Read now
Unlock full access