Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Just a question regarding a C function. So my function is the following: node* node_insert (node *root, char* data, int (*cmp)(const void* x, const void*
Just a question regarding a C function.
So my function is the following:
node* node_insert (node *root, char* data, int (*cmp)(const void* x, const void* y));
The (*cmp) would be a comparison function. I wrote a function with the following parameters:
void* mem_ex (const void *x, const void *y);
I'm just wondering how I would call node_insert in main.
Would I do something like:
node_insert(*pointer, *pointer, mem_ex(*pointer, *pointer))
or
node_insert(*pointer, *pointer, *mem_ex){
TO_DO
cmp(*pointer, *pointer)}
or something else I can't quite think of.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started