[ LUGOS ] bash script loop

Boštjan Muller [NEONATUS] neonatus na gimp.thz.net
Tor Sep 7 00:21:52 CEST 1999


* On 06-09-99 at 20:34 Jure Koren (jure na gimp.thz.net) wrote:
+----Here quoted text begins----+
> 1000. Torej, domaca naloga: kako bi zanko spremenil, da bi nehal
> loopat, ko pritisnes n (HINT: man bash)?
+----and here the quote ends----+
Domača naloga

let i=1
while [ $i -lt 1000 ]
do
echo -e "Do you wanna have phun? (N/y) : "
read ans
if [ "$ans" = "y" -o "$ans" = "Y" ]; then
echo -e "Please grab your nose and blow it hard than press Enter!"
read 
echo "Nose blown!"
fi
if [ "$ans" = "n" -o "$ans" = "N" ]; then
echo -e "Nose still full!"
sleep 3
exit 0
fi
done

THX za hint

Boštjan

-- 
Boštjan Müller [NEONATUS], NEONATUS na bigfoot.com, http://surf.to/NEONATUS
      ICQ #:7506644, For my PGP key finger: neonatus na gimp.thz.net
           RSA id: 0x90178DBD, Powered by S.u.S.E. Linux 6.0.
       Mother told me to be good, but she's been wrong before.       




Dodatne informacije o seznamu Starilist