A.i()

Read(504) Label: pure sequence,

Description:

Convert a specified sequence to a pure sequence.

Syntax:

A.i()

Note:

The function converts sequence A to a pure sequence. A pure sequence is a sequence where members have same data type.

 

The conversion is impossible when members of the sequence do not have same data type. Error is reported when members are modified and a pure sequence becomes not pure. When the computation involves an ordinary sequence or when it is expected that the result of the computation is not a pure sequence, the specified sequence will be automatically converted to an ordinary one.

Parameter:

A

A sequence

Return value:

A pure sequence

Example:

 

A

 

1

=["a","c","d","e","f"]

 

2

=A1.i()

Convert sequence A1 to a pure sequence.

3

=[1,2,3,4,5,6,7,"a"]

 

4

=A3.i()

As members of A3’s sequence don’t have same data type, error is reported when trying to convert it to a pure sequence.

5

=A2(3)=8

Error is reported during execution of the expression because we change the 3d member in A2 to 8 and the originally pure sequence becomes not pure.