Count Number Of Substrings Coding Ninjas