We have seen how to manipulate the value assigned to a variable and an integer so far, and then reassign this value to another variable or the same one. But why use two operations when you can alter the value of a variable and reassign it at the same time using the assignment operators?
Assignment operators
The += operator
This operator adds a quantity to the value of the variable and assigns the outcome to the variable itself, but to clarify its use, let's rewrite one of the examples we've seen before:
#!/bin/bash
echo "Hello user, please give me a number: "
read user_input
echo "And now another one, please: "
Adding
echo "The user_input variable value is: ${user_input}"
echo...