PlayStation Interview Question

Program to count occurrence of a given character in a string.