Hello all, 

Given:

check: func [n m] [
    print ["Considering" block/:n "and" block/:m "(positions" n "and" m "in the 
block):"]
    either same? block/:n block/:m [
        print "they are the same word"
    ] [
        either equal? block/:n block/:m [
            print "they are not the same word, but they are equal"
        ] [
            print "they are not equal"
        ]
    ]
]

we have:

>> alias 'aaa "bbb"
== bbb
>> block: [aaa bbb aaa Aaa]
== [aaa bbb aaa Aaa]
>> append block use [aaa] ['aaa]
== [aaa bbb aaa Aaa aaa]
>> check 1 2
Considering aaa and bbb (positions 1 and 2 in the block):
they are not the same word, but they are equal
>> check 1 3
Considering aaa and aaa (positions 1 and 3 in the block):
they are the same word
>> check 1 4
Considering aaa and Aaa (positions 1 and 4 in the block):
they are not equal
>> check 1 5
Considering aaa and aaa (positions 1 and 5 in the block):
they are not the same word, but they are equal
>> check 2 4
Considering bbb and Aaa (positions 2 and 4 in the block):
they are not equal

Regards,
   Gabriele.
-- 
Gabriele Santilli <[EMAIL PROTECTED]>  ---  http://www.rebol.com/
Colella Chiara software division --- http://www.colellachiara.com/

-- 
To unsubscribe from the list, just send an email to 
lists at rebol.com with unsubscribe as the subject.

Reply via email to