Some refactoring:
* typeset is obsolete (use declare instead)
* we can use (( )) instead of anything else (no need to use let or $(()) )
* proper variable quoting (always quote your variables like "$this")
* read without -r makes no sense (use "read -r" by default. Everywhere!)
* there is no need to use ${var}, just write $var (even if some freak from google tells you to do so)
* do not echo variables directly (why? try this: var=-n; echo "$var")
There is no need to use .sh extension (on GNU/Linux we use shebang instead!)