Re: IF statement and multiple options

2006-10-19 Thread Tom Phoenix
On 10/19/06, Robert Hicks <[EMAIL PROTECTED]> wrote: I am currently building the IF statement like: if ($project_name eq 'Proj1' || $project_name eq '' && $task_name eq '') Because logical-and is higher precedence than logical-or, that condition is the same as this: $project_name eq 'Proj

Re: IF statement and multiple options

2006-10-19 Thread Rob Dixon
Robert Hicks wrote: > I am currently building the IF statement like: > > if ($project_name eq 'Proj1' || $project_name eq '' && $task_name eq '') > > > That works but I was wondering if I can do this: > > if ($project_name eq ('Proj1' || '') && $task_name eq '') > > Less typing... : ) No. Because

IF statement and multiple options

2006-10-19 Thread Robert Hicks
I am currently building the IF statement like: if ($project_name eq 'Proj1' || $project_name eq '' && $task_name eq '') That works but I was wondering if I can do this: if ($project_name eq ('Proj1' || '') && $task_name eq '') Less typing... : ) Robert -- To unsubscribe, e-mail: [EMAIL PROT