Re: Syntax for OR

new topic     » goto parent     » topic index » view thread      » older message » newer message
cp said...

It seems that this syntax is supported ?

if seqConn[1] = 1 or 3 then 

and is equivalent to..

if seqConn[1] = 1 or seqConn[1] = 3 then 

casey

As others have said that is not what it does, I believe the language construct you are looking for is

if find(seqConn[1],{1,3})!=0 then 

The "!=0" could legally be omitted, but I think it clarifies the intent.

Perhaps the language should have the construct

if seqConn[1] in {1,3} then 

but at present it does not, and I'm not sure if that would play nicely with maps - perhaps someone who uses them regularly could chime in.

Pete

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu