Tree of Java data Structures and two-fork tree

Source: Internet
Author: User

From here, we will be explaining the Java data structure, is it ready? Let ' s go~~

The data structure model in Java can be divided into several parts:

1. Linear structure

2. Tree-shaped structure

3. Graphic or mesh structure

In the next few chapters, we will explain these data structures separately, mainly through the way of Java code.

Today's explanation is: Java linear structure

The tree structure of Java data structure

Before we learned about the linear structure of Java data structures in the first few chapters, we are going to learn the tree structure of Java from now on.

Tree for us to ordinary Java programmers, perhaps the usual time we seem to feel that it does not exist. But that's not true.

In fact, the JDK has been packaged for us, so give us an illusion that the tree data structure is very far away from us.

Give an example: TreeMap this set of framework, the bottom is the use of red and black trees ...

The following is a simple introduction to the data structure of the tree (if you want to know the details, please own Baidu Bar ~ Pro).

1. nodes in a tree can have several child nodes, but only one parent node per child node.

This is like a couple may have more than one child, but each child can have only one pair of parents.

2. classification of Trees

Tree of Java data Structures and two-fork tree

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.