Use C programming to answer the question:
8.3 LAB: Warm up: Contacts
A linked list is built in this lab. Make sure to keep trackof the head node.
(1) Complete main.c to define the struct ContactNode with thefollowing data members:
(2) Add the following functions:
Ex: if the name is Roxanne Hughes and the phone number is443-555-2864, PrintContactNode() outputs:
(2) Define main() to read the name and phone number for threecontacts and output each contact. Create three ContactNodes and usethe nodes to build a linked list. (2 pts)
Ex: If the input is:
the output is:
(3) Output the linked list using a loop to output contacts oneat a time. (2 pts)
Ex:
#include <stdio.h>#include <string.h>
typedef struct ContactNode_struct { /* Define ContactNode struct here. */
} ContactNode;
/* Define the functions here. */
int main(void) { /* Type your code here. */
}return 0;}
Use C programming to answer the question: 8.3 LAB: Warm up: Contacts A linked list is built in this lab. Make sure to ke
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am