What is a position in terms of sequence?

I am trying to learn about the abstract data types of a "sequence", and I was told that it has both rank and position. The rank is the number of elements that come before this element, but what is the position?

+5
source share
2 answers

This is a relative relative, as in a linked list, you can only go to the next (or, possibly, to the previous) node.

0
source

Position An element in a sequence is the index at which this value appears. For example, in the sequence

137 42 13 99 59

The number 137 is in index 0, and the number 42 is in index 1.

- , . , 137 4, 42 1 .. , .

, !

+2

All Articles