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 / 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 |
What is the difference between a stack and an array?
What are the two types of data?
Can we add duplicate keys in a hashmap? What will happen if we attempt to add duplicate values?
What is time complexity of arrays sort?
Program to remove duplicate elements in an array.
How does hashset maintain order?
Why do we use arrays?
Mention a few applications of linked lists?
How to use appendNode() in linkedlist()?
What are the objectives of studying data structures?
which notations are used in evaluation of arithmetic expressions using prefix and postfix forms?
Differentiate between collection and collections.