The echo command prints to standard output. However we know that it is good practice to redirect the error messages to standard error, lest the errors be redirected along with the output.
So, many languages provide features for writing to the standard error. (example: sys.stderr for Python)
For bash users, it is possible to redirect the echo output to standard error. We use the 1>&2 operator.
$ echo “#Error: Invalid calculation” 1>&2
Remember, this works only with bourne shells