It is an important feature of "using" Cshell TCshell.
switch ($var1)
case yes | YES:
echo Case: Yes; breaksw
case [nN][oO]:
echo Case: No; breaksw
default:
echo Case: default; breaksw
endsw
Why doesn't "Using Csh and Tcsh" have any examples of the "switch/case" function?
-
Hello Larry,
Thanks for your interest of Using csh & tcsh. It does appear as if example code isn't available on the catalog page for the book, and due to when this book was published it might appear as if this wont be made available.
Best regards,
Paul
O'Reilly Media -