To caps or not to caps that is the question?
derek.davis at gmail.com
Tue Dec 18 22:25:08 MST 2007
On Dec 18, 2007 4:14 AM, Steve <smorrey at gmail.com> wrote:
> Here are the relevant lines.
> for(; counter < length; counter++)
> coin = RandomNumber(0,100);
> letter = (letter == oldletter) ? ((coin <= 60) ?
> PickChar(vowels) : PickChar(consonants)) : letter;
> letter = (counter == 0) ? toupper(letter) : letter;
> name += letter;
> oldletter = letter;
Well, I'm a big printf fan for debugging when you can't use a
debugger. I'd print the value of counter before the loop starts and
first thing within the loop, just to make sure it's what you expect.
Then print out letter right after it should be capitalized. See what
the values are, that should tell you what's failing.
More information about the PLUG