Write a menu driven program to perform the following operations in a header linked list by using suitable user defined functions for each case. The head node keeps the count of the total number of nodes in the list. The data node keeps the student information: Name, Roll No, CGPA, Address_City, Branch.
1. Create
2. Display student information
3. Display the total number of nodes (in O(1) time)
4. Display the student's details belonging to a particular branch
5. Display the student's details securing > 7.5 CGPA and belonging to a given branch.
Write a program to perform addition and multiplication for given two sparse polynomials. Create a node for each term in the given polynomial.
2. Write a program to perform transpose for a given sparse matrix. ( Row major order)
Note: The last date for submission is 03-9-2021
Note: Implementation can be done either in C or C++ for questions 1 and 2.
Harry loves numbers in the range [m1, m2] (m1 and m2 included). carry decides to gift harry an array of numbers for his birthday. harry wants to find the number of pairs of indices [l, r] for which the sum of all the elements in the range [l, r] lies between m1 and m2.
Harry loves numbers in the range [m1, m2] (m1 and m2 included). carry decides to gift harry an array of numbers for his birthday. harry wants to find the number of pairs of indices [l, r] for which the sum of all the elements in the range [l, r] lies between m1 and m2.
Now improvise this algorithm, assuming all numbers are positive integers.
Write a program to copy the contents of one stack to another stack in the same order without using any extra data structure.
Implement PUSH, POP, and TRAVERSE operations on a stack using linked list.
Implement PUSH, POP, and TRAVERSE operations on a stack using array.
Implement polynomial addition and multiplication using linked lists.