/media/sda-magnetic/david/david2/david2/Dokumente/informatik/linux/bash/bash-2022-09-16/out2.txt


#!/bin/bash 

l=$(ls)

for s in $l
do
    if [ "$s" != "all.sh" ]
    then
        if [ "$s" != "out.txt" ]
        then
            if [ "$s" == "ifthenelse.sh" ]
            then
                echo "David Vajda" | /bin/bash "$s" >> out.txt
            elif [ "$s" == "io.sh" ]
            then 
                echo "David Vajda" | /bin/bash "$s" >> out.txt
            else
                /bin/bash "$s" >> out.txt
            fi
        fi
    fi
done


for s in $l
do
    if [ "$s" != "all.sh" ]
    then
        if [ "$s" != "out.txt" ]
        then
            if [ "$s" == "ifthenelse.sh" ]
            then
                echo "Tux User" | /bin/bash "$s" >> out.txt
            elif [ "$s" == "io.sh" ]
            then 
                echo "Tux User" | /bin/bash "$s" >> out.txt
            else
                /bin/bash "$s" >> out.txt
            fi
        fi
    fi
done


for s in $l
do
    if [ "$s" != "all.sh" ]
    then
        if [ "$s" != "out.txt" ]
        then
            if [ "$s" == "ifthenelse.sh" ]
            then
                echo "Max Mustermann" | /bin/bash "$s" >> out.txt
            elif [ "$s" == "io.sh" ]
            then 
                echo "Max Mustermann" | /bin/bash "$s" >> out.txt
            else
                /bin/bash "$s" >> out.txt
            fi
        fi
    fi
done
####################################################
#### Naechste
####################################################
#!/bin/bash 

a=(Hallo sagt David Vajda)
a+=(aber das auch)

for s in ${a[@]}
do
    echo "$s"
done

i=1
while [ $i -le 7 ]
do 
    echo "${a[$(($i-1))]}"
    i=$(($i+1))
done
####################################################
#### Naechste
####################################################
 #!/bin/bash
 
 l=$(ls)
 
 for s in $l
 do
    if [ "$s" != "out2.txt" ]
    then
        if [ "$s" != "gartenzaun.txt" ]
        then
            cat "$s" >> out2.txt
            cat "gartenzaun.txt" >> out2.txt
        fi
    fi
 done
####################################################
#### Naechste
####################################################
#!/bin/bash 

l=$(ls)

for s in $l
do
    echo $s
done
####################################################
#### Naechste
####################################################
#!/bin/bash 

read -p "Geben Sie ihren Namen ein: " name 
echo "$name"

if [ "$name" == "David Vajda" ]
then 
    echo "Sie sind ich"
elif [ "$name" == "Tux User" ]
then
    echo "Sie sind Linux User"
else
    echo "Ueber Sie sind keine Informationen bekannt"
fi

####################################################
#### Naechste
####################################################
#!/bin/bash 

read -p "Geben Sie ihren Namen ein: " name 
echo "$name"
####################################################
#### Naechste
####################################################
Hallo
sagt
David
Vajda
aber
das
auch
Hallo
sagt
David
Vajda
aber
das
auch
all.sh
array.sh
cmd.sh
ifthenelse.sh
io.sh
out.txt
shebang.sh
while.sh
David Vajda
Sie sind ich
David Vajda
#!/bin/bash
Hallo zum 1.
Hallo zum 2.
Hallo zum 3.
Hallo zum 4.
Hallo zum 5.
Hallo zum 6.
Hallo zum 7.
Hallo zum 8.
Hallo zum 9.
Hallo zum 10.
Hallo zum 11.
Hallo
sagt
David
Vajda
aber
das
auch
Hallo
sagt
David
Vajda
aber
das
auch
all.sh
array.sh
cmd.sh
ifthenelse.sh
io.sh
out.txt
shebang.sh
while.sh
Tux User
Sie sind Linux User
Tux User
#!/bin/bash
Hallo zum 1.
Hallo zum 2.
Hallo zum 3.
Hallo zum 4.
Hallo zum 5.
Hallo zum 6.
Hallo zum 7.
Hallo zum 8.
Hallo zum 9.
Hallo zum 10.
Hallo zum 11.
Hallo
sagt
David
Vajda
aber
das
auch
Hallo
sagt
David
Vajda
aber
das
auch
all.sh
array.sh
cmd.sh
ifthenelse.sh
io.sh
out.txt
shebang.sh
while.sh
Max Mustermann
Ueber Sie sind keine Informationen bekannt
Max Mustermann
#!/bin/bash
Hallo zum 1.
Hallo zum 2.
Hallo zum 3.
Hallo zum 4.
Hallo zum 5.
Hallo zum 6.
Hallo zum 7.
Hallo zum 8.
Hallo zum 9.
Hallo zum 10.
Hallo zum 11.
####################################################
#### Naechste
####################################################
#!/bin/bash 

echo "#!/bin/bash"
####################################################
#### Naechste
####################################################
#!/bin/bash 

i=0

while [ $i -le 10 ]
do 
    echo "Hallo zum $(($i+1))."
    i=$(($i+1))
done
####################################################
#### Naechste
####################################################