C++ Linked List Simple Project (C++ Only) - repost 2
$10-30 USD
Completed
Posted over 10 years ago
$10-30 USD
Paid on delivery
DUE BY: December 18th
NOTE: Please only SIMPLE code, no advanced techniques
Given the definition and implementation of the
singly linked list, add the following member functions to the linked list (assuming
list1 is an object of the class IntSLList)
1. [login to view URL]()
This member function reverses a singly linked list using only one
pass through the list.
For example, if the list has the values
1,2,3,4,5, then [login to view URL]() would reverse the list to start with
5,4,3,2,1.
If the list is empty, print an error message
2. [login to view URL]()
This member function deletes all the nodes of
[login to view URL] the list is empty, print an error message
3. [login to view URL](list2)
This member function appends
list2 to list1 and then removes all the nodes of list2.
If both list1 and list2 are empty, print an error message.
4. [login to view URL](value) where value can be any integer
This member function takes any integer value and multiplies all the nodes (info) by the value of that integer.
5. [login to view URL](value)where value can be any integer
This member function returns the frequency of a given integer in the linked list. If the list is empty, print an error message
6. [login to view URL]()
This member function returns the number of nodes in the list
[login to view URL](value) where value can have 0 (ascending order) or 1 (descending order)
Sort the linked list.
[login to view URL](n,k) This member function removes all nodes from the nth node
through the kth node.
For example, [login to view URL](5,7) would remove the 5th, 6th and 7th nodes.
The member function should check that the values of n and k are less than or equal to the number of nodes in the list
Needed:
Header files for the linked list classes
Source code files (one for each class implementation).
Source code file that contains main() to test the new member functions.
Make sure you include a test for each of the new member functions with appropriate test conditions.
An executable file of your program (main() + class implementations)