Write a program for creating a linked list by dynamically


Write a program for creating a linked list by dynamically allocating memory for desired number of nodes. The linked list should be populated based on file I/O. Your program should include following capabilities: (a) adding nodes at the beginning of the list and at a specific index. (b) deleting nodes from the beginning of the list and based on a specific index. (c) processing command-line arguments: -f : name of input file. -o : name of output file. You can assume that file I/O will be in text format. Populate a linked list by reading from input file. The file will contain two lines of numbers. Your program should do the following: (a) Create a node in the linked list corresponding to each number read from the first line of the file. (b) Delete nodes whose indices are specified as the even numbers in the second line of the input file. (c) Add nodes whose indices are specified as the odd numbers in the second line of the input file. (d) Write out the list of numbers in the output file.

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: Write a program for creating a linked list by dynamically
Reference No:- TGS0662202

Expected delivery within 24 Hours