Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • 3
    What is the value in $input? Also, the case statement is partial (not closed by esac), and you're not using $val anywhere. Commented Mar 29, 2018 at 7:39
  • Should always be case "$input". It seems to me that the esac is missing. Or shall $input be printed only in the last case? And why $input and not $val? Strange code... Commented Mar 29, 2018 at 7:42
  • 1
    @HaukeLaging Quoting $input in the case statement is good practice, but actually not necessary. unix.stackexchange.com/questions/68694/… (note, I always quote the expansion in case statements) Commented Mar 29, 2018 at 7:51
  • yeah ..it was by mistake i didnot esac Commented Mar 29, 2018 at 8:24