Advertisement
Guest User

Untitled

a guest
Oct 29th, 2014
245
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.48 KB | None | 0 0
  1. #! /bin/sh
  2. echo -n "Continue y/n: "
  3. read item
  4.  
  5. case "$item" in
  6.         y|Y) echo "OK!!!"
  7.                 ;;
  8.         n|N) echo "Sorry ..."
  9.                 exit 0
  10.                 ;;
  11.         *) echo "fail "
  12.                 ;;
  13. esac
  14.  
  15. echo -n " 1 or 2: "
  16. read choise
  17.  
  18. case "$choise" in
  19.         1) echo "Correct! "
  20.                 ;;
  21.         2) echo "No correct"
  22.                 ;;
  23.         *) echo "Fail "
  24.                 exit 0
  25.                 ;;
  26. esac
  27.  
  28. echo  " Bye!"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement