I have to write a script that takes a sentence and prints the word count, character count (excluding the spaces), length of each word and the length. I know that there exist
code
var=(one two three) length=${#var[@]} echo $length
output
3