Added method to found character frequency

Also added a JUnit test