teil02 teil11 und teil12

This commit is contained in:
2024-07-29 08:01:42 +02:00
parent b1871443df
commit ae9e94b262
9 changed files with 143 additions and 3 deletions

View File

@@ -1,14 +1,19 @@
#and.sh
counter='1'
test=1
echo "${counter}"
let counter=counter+1
echo "${counter}"
let counter=counter+1
if [ ${counter} -eq 3 ] && [ ${counter} -gt 2 ]; then
echo "drei"
if [ ${counter} -eq 3 ] && [ ${test} -eq 2 ]; then
echo "0-drei"
fi
if [ ${counter} -eq 3 ] && [ ${test} -eq 1 ]; then
echo "1-drei"
fi
let counter=counter+1
echo "${counter}"

19
teil11/not.sh Normal file
View File

@@ -0,0 +1,19 @@
#not.sh
counter='1'
test=1
echo "${counter}"
let counter=counter+1
echo "${counter}"
let counter=counter+1
if ! [ ${counter} -eq 3 ] || [ ${test} -eq 2 ]; then
echo "0-drei"
fi
if [ ${counter} -eq 3 ] || [ ${test} -eq 1 ]; then
echo "1-drei"
fi
let counter=counter+1
echo "${counter}"

19
teil11/or.sh Normal file
View File

@@ -0,0 +1,19 @@
#or.sh
counter='1'
test=1
echo "${counter}"
let counter=counter+1
echo "${counter}"
let counter=counter+1
if [ ${counter} -eq 3 ] || [ ${test} -eq 2 ]; then
echo "0-drei"
fi
if [ ${counter} -eq 3 ] || [ ${test} -eq 1 ]; then
echo "1-drei"
fi
let counter=counter+1
echo "${counter}"