j
k
j a
j l
May be this ```sh #!/bin/sh
get_answer () { value=$1 question=$2 if [ "${value}" = "ask" ]; then echo -n "$question" read value fi ANSWER=$(echo ${value} | grep -o -e '[YyNn]' | sed -e 's/Y/y/' -e 's/N/n/') }
get_answer ask "My question?" ```
Attachments:
Back to the thread
Back to the list