as seen in attachment. I cannot figure out what I've done wrong.
as seen in attachment. I cannot figure out what I've done wrong.
??Code:counts[letter]
Your index variable is i - not letter.
letter runs from 65 (i = 0) .... 91 (i = 26).
There is no problem with the allocation - it's the printing that's messed up.
The Unforgiven
OMG I cannot believe I missed it. I spent hours looking at that.
Thanks
When posting code in future - use the code tags (the # button on the toolbar), rather than posting a screen shot .
Also - can you mark this thread as solved - go to Thread Tools.
Tony - Happy to try to help.
Unless otherwise stated - all code posted by me is untested. Remember to Mark the Thread as Solved.
Ubuntu user number # 24044 Projects : TimeWarp - on the fly Backups
BTW, to keep it more readable, you could've also done:
just so that it's explicitly stated what you're trying to doCode:letter = i + 'A';
The Unforgiven
ok thankyou
Bookmarks