penum()

Read(2018) Label: judge, enum group,

Here’s how to use penum() function.

E. penum()

Description:

Judge to which enum group an object belongs.

Syntax:

E.penum(y)

Note:

The functions judges to which group of sequence/record sequence E member y belongs, and returns the ordinal number(s) of the group(s), i.e. ordinal number(s) of the record(s) of E that satisfy the grouping condition.

Parameter:

E

A sequence/record sequence

y

A member; allowed to be omitted

Option:

@r

Return the ordinal numbers of all the groups satisfying the grouping condition, and the default is to return the ordinal number of the first group

@n

If no eligible sequence member of E is found, return the length of E plus 1

Function keyword:

?

Represents the value of y

Return value:

Sequence/Integer sequence

Example:

Ø  E is the sequence

 

A

 

1

=["?<=70&&?>=60","?>=70 && ?<=90","?>=90"]

Use y to replace ? in the grouping conditions when computing.

2

=A1.penum(90)

2; the ordinal number of the first group satisfying the condition will be returned.

3

=A1.penum@r(90)

[2,3]; return the ordinal numbers of all the groups.

4

=A1.penum@n(43)

4.

Related function:

P.enum()