The function f(x) takes a string input and returns the number of distinct substrings of the input that contain the letter "a".
