How to determine some kind of structure or logical structure of the data storage structure or structures?

When a structure, such as arrays, linked lists, trees, graphs, only one is defined in the logical structure, the physical structure and there are two options, then the logical structure belongs to the structure;

In contrast, when this structure is added based on the original some defined, such that only one is defined in the physical structure, this structure belongs to physical (storage) configuration;

 

 

  Example 1: What part of the stack structure?

  Analysis: logical structure stack can only belong to a linear structure, and the physical structure that may be used sequentially stored (array) may be used store chain (chain), so that the stack is a logical structure.

  Example 2: binary clue what belongs to the structure?

  Analysis: First, it can give a binary tree is a data structure, but leads binary tree list structure after adding cues (sequential storage can not be used), that is, it is only one of the internal computer memory structure, the physical structure .

 

Point of difference of the logical structure and the storage structure comprising: logical structure data is independent of the storage structure in a computer, the data storage has many different options. For example, the stack is a logical structure that may be used with the chain may be sequentially stored in memory.

The data structure is a description of the logical structure may be described in turn may store the data structure and operation, must contain three or more elements. Therefore, as the order table, hash table, are singly-linked list data structure.

Guess you like

Origin www.cnblogs.com/wonker/p/11236370.html