Dateien des bash Tutorioals auf raspithek.de
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
314 B

#! /usr/bin/bash
# File: return-value-echo2.sh
function square() {
echo $(( ${1} * ${1} ))
}
s2=$(square "2")
s4=$(square "4")
s3=$(square "3")
s32=$(square "32")
echo "Das Quadrat von 2 ist ${s2}"
echo "Das Quadrat von 4 ist ${s4}"
echo "Das Quadrat von 3 ist ${s3}"
echo "Das Quadrat von 32 ist ${s32}"