how a polynomial such as 6x^6+4x^3-2x+10 can be represnted
by linked list?write an algorithm that reads such an polynomial
Answer Posted / poojithap2
the polynomial contained in the coefficiant&exponant of x
6.0 4.0 -2.0 10.0
....... .....
6 3 1 0
...... ..... ..... ......
---> ---> ------> --->
...... ..... ..... .......
alg:
if empty list
if polynomial=NULL
then
when('zero polynamial')
return
[traverse list]
reepeat while polynomial!=NULL
set result=derivative of polynomial
write result
set polynomial=next node of polynomial
end loop
return
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
How do you increase the capacity of an arraylist?
Suppose in an integer array, there is 1 to 100 number, out of one is duplicate, how to find?
Write a program for reversing the Single Linked List?
What are the two traversal strategies used in traversing a graph?
where do you use double linked list?
What is a queue in data structure?
What is an acyclic graph?
What is bubble sort with example?
What is modcount in hashmap?
What are all the classes and interfaces that are available in the collections?
How does max heap work?
What is meant by binary tree?
What is the difference between hashset and hashtable?
What is Insertion sort, selection sort, bubble sort( basic differences among the functionality of the three sorts and not the exact algorithms)?
What is difference between list set and map?