hima890 / binary_trees

A collection of C programs for learning and implementing binary tree operations, including traversal, insertion, deletion, and validation. Ideal for understanding fundamental data structures and algorithms in C programming.
GNU General Public License v3.0
0 stars 0 forks source link

0. New node #1

Closed hima890 closed 3 months ago

hima890 commented 3 months ago

Write a function that creates a binary tree node

Prototype: binary_tree_t binary_tree_node(binary_tree_t parent, int value); Where parent is a pointer to the parent node of the node to create And value is the value to put in the new node When created, a node does not have any child Your function must return a pointer to the new node, or NULL on failure alex@/tmp/binary_trees$ cat 0-main.c

include

include "binary_trees.h"

/**

hima890 commented 3 months ago

I will create a branch and look it up

hima890 commented 3 months ago

The task was simple you crate a node then assign it valuse

hima890 commented 3 months ago

checker agree