List expressions are used to determine if a string or number is in a specified list. For example, if you wanted to change the color of every element on levels 15, 23, and 45 to red, you could use the .in. (in the list of) operator and the list expression shown below.
if (level .IN. 15, 23, 45) then color = "red" endif
There is also the .NI. (not in the list of) operator for determining if a value is not in the list.
Although integers and real numbers can exist together within a list, you cannot mix numbers and strings. Also, both operands of a list operator must be the same type. A keyword whose value is a string, such as cellname, can also be included in a list of strings.
A consecutive range of numbers can be indicated with the following notation.
number1 - number2
This construct specifies that if number1 and number2 are both integers, all integers in the range of number1 to number2 are part of the list. If either number is a real, any number greater than or equal to number1 and less than or equal to number2 is included in the list. The expressions below are examples of valid list expressions.