MCPcopy Create free account
hub / github.com/codemistic/Data-Structures-and-Algorithms / newNode

Function newNode

left view of tree.cpp:12–19  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

10
11
12struct Node *newNode(int item)
13{
14 struct Node *temp = (struct Node *)malloc(
15 sizeof(struct Node));
16 temp->data = item;
17 temp->left = temp->right = NULL;
18 return temp;
19}
20
21// left view of a binary tree.
22void leftViewUtil(struct Node *root,

Callers 1

mainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected