I wanna calculate the frequency of its character on an array.
There are several ways ways to do this
A Simple brute-force over the array would need O(