The collection structure-----Regardless of the relationship between the data, each data element is "equal"
Linear structure-----One-to-many correspondence, except that the first element has no precursor, and other data elements have only precursors and successors.
The tree structure-----One corresponding to multiple, except the root element, and the other data elements have a unique precursor.
The graph structure-----multiple corresponding to one element may have multiple precursors and successors
1. A linear table is a finite sequence of data elements of the same type
2, the basic operation of the linear table
<1>int Length () const
Initial conditions: Linear table already exists
Operation Result: Returns the number of linear table elements
<2>bool Empty () const
Initial conditions: Linear table already exists
Operation Result: Returns TRUE if the linear table is empty, otherwise false
<3>void Clear ()
Initial conditions: Linear table already exists
Operation Result: empty linear table ·
<4>void Traverse (void (* Visit) (elemtype&))
Initial conditions: Linear table already exists
Operation Result: the function (* Visit) is called on each element of the linear table in turn.
<5>statuscode setelem (int position,const elemtype &e)
Initial conditions: Linear table already exists, 1<=position<=length ()
Operation Result: Assigns the element of the position position of the linear table to the value E
<6>statuscode Delete (int position, elemtype &e)
Initial conditions: Linear table already exists, 1<=position<=length ()
Operation Result: Delete the element of the position position of the linear table and return its value with E (Assign the value to e), the length minus one
<7>statuscode Insert ((int position, const elemtype &e)
Initial conditions: Linear table already exists, 1<=position<=length ()
Operation Result: Insert element e before the position position in the linear table, length +1
<8>statuscode Getelem (int position, elemtype &e) const
Initial conditions: Linear table already exists, 1<=position<=length ()
Operation Result: Returns the position element of the linear table with E
Elemtype element type///
3. There are two ways to implement linear tables------sequential tables and linked lists
Data Structure------------Linear table