Computer Science Canada Character Entering and checking |
Author: | Blade [ Wed Apr 16, 2003 12:02 pm ] |
Post subject: | Character Entering and checking |
is there any way that i could enter a character, check to see if its a word, then check to see if tis been entered again... like i have a word - Cat... have the user enter a letter and check to see if the letter is in the word, but also check to see if he's entered that same letter before.. I'm not asking you to do this for me... i would just like to have some help with it.. i've been sittin here in this damned boring class days tryin to figure out a way.. but i think i'm having a week long brain fart |
Author: | Delta [ Wed Apr 16, 2003 1:46 pm ] | ||
Post subject: | This is what I got | ||
I'm confused but this is what I got out of it
Don't copy just use as a template |
Author: | Blade [ Wed Apr 16, 2003 2:13 pm ] |
Post subject: | |
that isnt really it.... but its along that idea... what i meant was.. -enter a word -enter a letter -if the letter is in the word, but hasn't been guess before, you get a point -if the letter is in the word, but has been guessed, no points sorry my question wasnt very clear.. i try to, hopefully this one clears it up |
Author: | Catalyst [ Wed Apr 16, 2003 2:17 pm ] |
Post subject: | |
index should be able to help will tell u if its in the word |
Author: | Blade [ Wed Apr 16, 2003 2:20 pm ] |
Post subject: | |
yeah... i can check to see if its in the word, but i cant figure out to index the already guessed letters, and check to see if its been used before... it has to be in the same if statement... doesnt it? |
Author: | Catalyst [ Wed Apr 16, 2003 2:36 pm ] | ||
Post subject: | |||
it would be like this...
youll have to use captalization functions to normalize it but that is pretty much it |
Author: | Blade [ Wed Apr 16, 2003 2:39 pm ] |
Post subject: | |
awwww i feel so stupid now ![]() ![]() |
Author: | Blade [ Thu Apr 17, 2003 4:14 pm ] |
Post subject: | |
also... i was playin around and i remembered that it was case sensitive... any way i can take this off? or get around it? |
Author: | Tony [ Thu Apr 17, 2003 4:26 pm ] |
Post subject: | |
i belive someone already posted a function for converting cases around. you add some number to the ASCII value (i dont remember which one) |