It is composed of a name and a value. A variable name can be up to twenty characters long and must start with a letter. A dollar sign followed by a variable name is replaced with the contents of the variable by the shell. You can clear this value by using the unset command. You can assign the output of a command to a variable by using backwards single quotes around the command itself.
Variables can come in very handy.
For instance, if there is a directory which has a long pathname, that you use quite often, then you could set up a variable for it. There are some special variables in the shells. If you put the command set echo at the beginning of a shell script, every command will be echoed to the standard output. Be sure to put unset echo at the end if you are going to be executing more commands, or everything you type after running the script will also be echoed.