26.06.2015 Views

Unix/Linux

Unix/Linux

Unix/Linux

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

case/esacdddd<br />

caseddddd Cdddswitch/casedddesacdd caseddddd<br />

ddCddd casedddddddddddddddddShellddd<br />

caseddddddddWildcarddddddddddddddddd<br />

ddddd ;;ddddddddddddddddddddddd<br />

dddddddd esacdddddddCdddddbreakddd<br />

✞<br />

#! /bin/sh<br />

echo ”Is it morning? Please answer yes or no.”<br />

read YES OR NO<br />

case ”$YES OR NO” in<br />

yes|y|Yes|YES)<br />

echo ”Good Morning!”;;<br />

[nN]∗)<br />

echo ”Good Afternoon!”;;<br />

∗)<br />

echo ”Sorry, $YES OR NO not recognized. Enter yes or no.”<br />

esac<br />

✡✝<br />

✆<br />

ddd (ddddddd) <strong>Unix</strong>/<strong>Linux</strong>dddddddd 2009d12d 128 / 173

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!