Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Your DMM program must have a text-based interface which allows the user to selec

ID: 3665335 • Letter: Y

Question

Your DMM program must have a text-based interface which allows the user to select from a menu of options including: load, store, display, insert, delete, edit, sort, rate, and exit. The “load” option reads records from a file into a dynamic doubly linked list. The “store” command writes records, in a dynamic doubly linked list, to a file. “Display” prints records, and its attributes to the screen. This command must print either all records or a single record based on a search field. A search field may be any of the attributes belonging to a record. If a search field matches multiple records, then print the first match to the screen. The “insert” option collects information for each new song record and attributes from the user. The new song record must be placed into the list based on a selected sort option. By default, songs are inserted into the list alphabetically (‘a’ – ‘z’) according to artist. Other possible “sort” options include alphabetical ordering based on genre, or increasing numeric value based on rating. “Delete” removes a record from the list. Deletion is based on song title. The “edit” option must allow the user to find a record in the list with any search field. The user may modify any of the attributes in the record. The “rate” action must allow the user to assign a value of 1 – 5 to a song; 1 is the lowest rating and 5 is the highest rating. Lastly, “exit” saves the most recent list to a file.

A record is a struct type which consists of the following attributes:

I need help doing the sorting. And please do it in C

Explanation / Answer

Here is the way to do....


#ifndef Header_h
#define Header_h
void sort();
void load (struct listNode ** temp);
void display (struct listNode ** head);
struct listNode * makeNode (struct record * newData);
struct record * makeRecord(char*artist,char *album,char *song,char *genre,struct songLength *length, int ntp, int rating);
struct songLength * makeSongLength(int minutes, int seconds);
void insertNode1 (struct listNode ** old, struct listNode ** fresh);
{
char *artist[100];
char *album[100];
char *song[100];
char *genre[100];
struct songLength * length;
Corinthians ntp;
int rating;
};
typedef struct songLength
{
int minutes;
int seconds;
};
typedef struct listNode
{
struct record * data;
struct listNode * pNext;
struct listNode * pLast;
};

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote