Computer Science Canada

Index Question

Author:  mike200015 [ Sun May 22, 2005 7:20 pm ]
Post subject:  Index Question

If i use the index function to check if the user types in the right word, does it matter between upper and lower case letters? If i check for "a",and the user enters "A" will it work.

Author:  Cervantes [ Sun May 22, 2005 7:52 pm ]
Post subject: 

"Yarr!", yells Cervantes. "I've got meself a right-good idea, I do! Let's write ourselves arr program and find out!"

Turing:

var input : string
get input
if index (input, "A") ~= 0 then
    put "A was found"
end if
if index (input, "a") ~= 0 then
    put "a was found"
end if


Try inputting "Arr", "arr", and "Aarr". Don't forget to say the words your typing, and add some meaning to them!

YAr!!

Author:  zylum [ Mon May 23, 2005 12:27 am ]
Post subject: 

lol Laughing

yes it's case-sensitive


: