I wanted to know if there is a better way to code this situation of counting the number of occurances of each letter(case insensitive) and each number in a file, disregarding other characters. So far I have it completed by turning each line of the file into a string, than using loops, if-else logic, and isalpha and isdigit to walk through each string char by char to do this, updating as i go along. My question is there a simpler code to do this? I am fairly new to C programming. Thanks for help.

04-21-2008

zacs7

Yes, don't bother breaking it up into lines for one.

Without seeing how you're doing it, it's hard to say.

04-21-2008

Elysia

I'm thinking you might need an array and some char logic to use it as a map.