You are given the LinkedList header file, which is a complete and usable header file for the linked list data structure. You are expected to
You are given the LinkedList header file, which is a complete and usable header file for the linked list data structure. You are expected to write a custom function called insert_descending which will insert the objects to the Linked List in a descending order (azalan sira).
Second: You will write a C++ code including a main in which you will create a Linked List of integers, take 10 integers from the user and display them from the largest to the smallest number. You MUST USE the insert_descending function that you have written in the first part of the HW to sort the items from the largest to the smallest.
Sample Run
C:\Users\Himao\Desktop\hwImain.exe Enter an integer:5 Enter an integer:34 Enter an integer: -456 Enter an integer:78 Enter an integer:85655 Enter an integer:234 Enter an integer:55 Enter an integer:48 Enter an integer:6 Enter an integer:-77445 85655 234 78 55 48 34 6 5 -456 -77445 Process exited after 18.14 seconds with return value e Press any key to continue
Step by Step Solution
3.48 Rating (155 Votes )
There are 3 Steps involved in it
Step: 1
I have implemented the above program to insert elements in the linked list in descending order I hav...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