We’ll continue working with our linked list of points in the next video. This time we’ll learn how to automate the linking process between the points with the help of a function.
If you cannot see this codecast, please click here.
Check Your UnderstandingCheck Your Understanding
1.
Given the structure definition from the video,
struct point{
int x;
int y;
struct point * next;
};
what is the return type of the following function:
struct point * append (struct point * end, struct point * newpt) {
end->next = newpt;
return(end->next);
}