{"id":24522082,"url":"https://github.com/nickssilver/binary_trees","last_synced_at":"2025-03-15T13:11:22.869Z","repository":{"id":64837664,"uuid":"578699364","full_name":"nickssilver/binary_trees","owner":"nickssilver","description":"A project about Binary Trees in C and other tree-type data structures.","archived":false,"fork":false,"pushed_at":"2022-12-15T18:15:54.000Z","size":23,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-22T03:17:43.014Z","etag":null,"topics":["algorithm","c","data-structure"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nickssilver.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-12-15T17:10:52.000Z","updated_at":"2023-08-08T06:13:35.000Z","dependencies_parsed_at":"2022-12-15T20:40:01.705Z","dependency_job_id":null,"html_url":"https://github.com/nickssilver/binary_trees","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickssilver%2Fbinary_trees","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickssilver%2Fbinary_trees/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickssilver%2Fbinary_trees/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nickssilver%2Fbinary_trees/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nickssilver","download_url":"https://codeload.github.com/nickssilver/binary_trees/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243732296,"owners_count":20338839,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["algorithm","c","data-structure"],"created_at":"2025-01-22T03:17:48.235Z","updated_at":"2025-03-15T13:11:22.846Z","avatar_url":"https://github.com/nickssilver.png","language":"C","readme":"# 0x1D. C - Binary trees\n\u003chr\u003e\n\n## Description\nA binary tree is a data structure that is made up of nodes. Each node has at most two children, which are referred to as the left child and the right child. A binary tree can be used to store data in a hierarchical manner, allowing for efficient insertion, deletion, and search operations. Binary trees are commonly used in computer science for a variety of tasks, such as storing data in a sorted order, implementing efficient search algorithms, and more.\n\n## Learning Objectives\n\n* What is a binary tree\n* What is the difference between a binary tree and a Binary Search Tree\n* What is the possible gain in terms of time complexity compared to linked lists\n* What are the depth, the height, the size of a binary tree\n* What are the different traversal methods to go through a binary tree\n* What is a complete, a full, a perfect, a balanced binary tree\n\n## Usage\n\n* All files were created and compiled on Ubuntu 20.04 LTS on gcc 4.8.4 \\\nusing the flags -Wall -Werror -Wextra and -pedantic\n* All files were linted for syntax and style with [Betty](https://github.com/holbertonschool/Betty)\n\n## Table of contents\nFiles | Description\n----- | -----------\n[0-binary_tree_node.c](./0-binary_tree_node.c) | C function that creates a binary tree node\n[1-binary_tree_insert_left.c](./1-binary_tree_insert_left.c) | C function that inserts a node as the left-child of another node\n[2-binary_tree_insert_right.c](./2-binary_tree_insert_right.c) | C function that inserts a node as the right-child of another node\n[3-binary_tree_delete.c](./3-binary_tree_delete.c) | C function that deletes an entire binary tree\n[4-binary_tree_is_leaf.c](./4-binary_tree_is_leaf.c) | C function that checks if a node is a leaf\n[5-binary_tree_is_root.c](./5-binary_tree_is_root.c) | C function that checks if a given node is a root\n[6-binary_tree_preorder.c](./6-binary_tree_preorder.c) | C function that goes through a binary tree using pre-order traversal\n[7-binary_tree_inorder.c](./7-binary_tree_inorder.c) | C function that goes through a binary tree using in-order traversal\n[8-binary_tree_postorder.c](./8-binary_tree_postorder.c) | C function that goes through a binary tree using post-order traversal\n[9-binary_tree_height.c](./9-binary_tree_height.c) | C function that measures the height of a binary tree\n[10-binary_tree_depth.c](./10-binary_tree_depth.c) | C function that measures the depth of a node in a binary tree\n[11-binary_tree_size.c](./11-binary_tree_size.c) | C function that measures the size of a binary tree\n[12-binary_tree_leaves.c](./12-binary_tree_leaves.c) | C function that counts the leaves in a binary tree\n[13-binary_tree_nodes.c](./13-binary_tree_nodes.c) | C function that counts the nodes with at least 1 child in a binary tree\n[14-binary_tree_balance.c](./14-binary_tree_balance.c) | C function that measures the balance factor of a binary tree\n[15-binary_tree_is_full.c](./15-binary_tree_is_full.c) | C function that checks if a binary tree is full\n[16-binary_tree_is_perfect.c](./16-binary_tree_is_perfect.c) | C function that checks if a binary tree is perfect\n[17-binary_tree_sibling.c](./17-binary_tree_sibling.c) | C function that finds the sibling of a node\n[18-binary_tree_uncle.c](./18-binary_tree_uncle.c) | C function that finds the uncle of a node\n\n### Authors\n* [Nicks](https://github.com/nickssilver) - [@_pronicks](https://twitter.com/_pronicks)\n\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnickssilver%2Fbinary_trees","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnickssilver%2Fbinary_trees","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnickssilver%2Fbinary_trees/lists"}