CSc 3320 System-Level Programming
Summer 1999
Homework #3
Due: 21 July 1999 (Wednesday)
Write the code for the following functions:
Suppliers (supps.c)
---------
void makenull_supp(Snodeptr suppliers[]);
int member_supp(struct supp_element_type x, Snodeptr suppliers[],
Snodeptr *s);
int insert_supp(struct supp_element_type x, Snodeptr suppliers[]);
void print_suppliers(Snodeptr suppliers[]);
Parts (parts.c)
-----
void makenull_part(Pnodeptr *parts);
int member_part(struct part_element_type x, Pnodeptr parts,
Pnodeptr *p);
int delete_part(struct part_element_type x, Snodeptr suppliers[],
Pnodeptr *parts);
void print_parts(Pnodeptr parts);
void delete_all_supply_for_part(Pnodeptr q, Snodeptr suppliers[],
Pnodeptr *parts);
Supply (sp.c)
------
int delete_supply(struct supp_element_type x,
struct part_element_type y,
Snodeptr suppliers[],
Pnodeptr *parts);
int print_suppliers_given_part(struct part_element_type x,
Pnodeptr parts);
int print_parts_given_supplier(struct supp_element_type x,
Snodeptr suppliers[]);
void print_supply(Snodeptr suppliers[], Pnodeptr parts);
Submit a listing of all the files and keep the executable
file in {\tt db}.
You should download the following files and add code to
them to complete your assignment.