So I am working on a project and am having a bit of an issue. I need to have an HTML page with a Text Area, and I need to on a button click calculate how many of each letter in the alphabet are in the string in said Text Area.
For example in the string:
"The Quick Brown Fox Jumps Over the Lazy Dog"
The results would be:
A = 1, B = 1, C = 1, O = 4, etc.
The easiest way I can think to do this is to convert the contents of the Text Area to an array with each array element being a single character (if I could manage to exclude spaces, that would also be sweet) and then compare that Array, to a second array where each element is a different letter of the alphabet.
My biggest problem is that I have no idea how to do this. As the title says I'm using Javascript for this, and I've tried looking on here, as well as using Google, but am coming up with nothing. Thank you in advance for anyone who offers help :)