Securonix interview question

Bash scripting to search particular string and count it