You are given an grid which contains lower case English letters. How many times does the phrase "saba" appear horizontally, vertically, and diagonally in the grid?
The following word locations in the matrix are possible:
The first line contains the number of rows and the number of columns in the grid. Each of the next lines contains a string of length whith lower case English letters only.
Print the number of times the word "saba" appears in the grid.