Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Tree Library for C

Tags:

c

I want to store a general tree in C using parent pointer approach (a node store pointer to its parent node only). Is there any standard library for this?

Thanks in advance

like image 844
Ravi Gupta Avatar asked Jun 22 '10 08:06

Ravi Gupta


People also ask

Can we implement tree in C?

In the C programming language, we can implement a binary tree in a similar fashion like linked lists. We employ the use of structures in C.

What is tree library?

Tree Library. A TTree represents a columnar dataset. Any C++ type can be stored in its columns. A TTree, often called in jargon tree, consists of a list of independent columns or branches, represented by the TBranch class. Behind each branch, buffers are allocated automatically by ROOT.

Is there a library for trees in C++?

The tree. hh library for C++ provides an STL-like container class for n-ary trees, templated over the data stored at the nodes. Various types of iterators are provided (post-order, pre-order, and others). Where possible the access methods are compatible with the STL or alternative algorithms are available.

What is node of tree in C?

It begins with a root node, which contains the original key value. The root node has two child nodes; each child node might have its own child nodes. Ideally, the tree would be structured so that it is a perfectly balanced tree, with each node having the same number of child nodes to its left and to its right.


1 Answers

Google shows me to GNU C Library. Are you looking for something more?

like image 149
vpit3833 Avatar answered Sep 21 '22 20:09

vpit3833