Problem is with line:

>   either (equal? guess [pick secret-words 1])

Putting [] around the second argument of 'equal? is making it into a block,
while the first argument ('guess) is type string!   Simply leave out the [ ]
or use () to force precedence when needed (not needed here).

Russ

------------------------------------- 
At 08:14 PM 10/11/99 -0700, you wrote:
>I know that pick secret-words 1 is choosing "camel" and I am typing "camel"
>so I don't know why the first option of the either is not being chosen. Some
>guru please help!!
>
>REBOL [
>    Title:  "More than one secret word"
>    Date:   11-Oct-99
>    Author: "T.M. Brannon"
>    Email:  [EMAIL PROTECTED]
>    File:   %more-than-one-word.r
>    Purpose:    {
>        Play a guessing game
>    }
>    Category: [file script utility]
>]
>
>
>secret-words: [ "camel" "llama" "oyster" ]
>
>name:  ask "What is your name? "
>guess: ask "What is the secret word? "
>
>either equal? name "Randal"
> [ print "Hi Randal! No secret word required. You're the greatest!" ]
> [ print ["Hello" name "." ]
>   either (equal? guess [pick secret-words 1])
>  [ print "That's it!!!! You got it!!!" ]
>  [ print "Wrong loser." ]]
>
>
>
>
>
>

Reply via email to