I'm trying to learn how to build a tree (binary or non-binary). I found so many codes but I could not find clear explanation on the internet. If someone is familiar with how to build a tree please provide help/link.
Do you understand how a linked list works? Understanding how to build a binary tree builds somewhat on an understanding of how linked lists work (because the worst-case-scenario for a simple binary search tree would look remarkably like a linked list!). Certainly from the point of view of building the structure, you may find a singly-linked list to be an easier starting-point.
There are some in-depth tutorials which talk about lists, pointers and various different kinds of tree-like data structures at EternallyConfuzzled.
Thank you for replying. I couldn't follow the examples in the links you've posted. I've tried googling stuff but I haven't got to the basic information I need to understand.