First, the preface
Linear structure is a kind of basic data structure, which is mainly used to describe a single precursor and subsequent data relationship in the objective world. That is, "arrange one after another." The characteristic is that the data element presents a linear relationship. Ii. Introduction of the content
2.1 Linear Table
① Sequential storage: Insert the average number of moves is N/2, delete the average number of moves is (n-1)/2
② chain storage: Divided into many kinds of two-way linked list, circular linked list, static linked list. The test center is the writing list inserts, deletes the code.
2.2 Stacks and Queues
Characteristics:
① Stack: * * Advanced after the * *, can be recursive call;
② Queue: * * Advanced First OUT * *, can not be recursive call;
Storage mode:
2.3 Series
Defined:
A string is a special linear table in which the period data element is a character. A string is a finite sequence consisting of 0 or more characters. Generally remember s= ' a1a2....an ' where S is a string, and the sequence of characters enclosed in single quotes is a string value; AI (1〈=i〈=n) can be a letter, a number, or another character; the number of characters in a string is the length of the string. A string of zero length is called an empty string, and it does not contain any characters.
Storage mode:
① Sequential storage: A set of contiguous storage units to store string-valued character sequences.
② Chained storage: Each node can store a single character, or can store more than one character, this time to consider the storage density.
Three, contrast memory
Some of these concepts can be done by comparing memory, and some of the core of knowledge can be compared to learn, this is to provide you with the learning method, this is a good idea, memory profound, but also can improve their level. Iv. Summary
So through the constant attack, the time to harvest the results finally came. Data structure is to abstract their own things, through the control of this country, small knitting so constantly completed, refueling.
The next small story will bring you the "data structure" data structure and algorithm (i)--Nonlinear structure