Python Scripts: 2 Multiply two polynomials

preview_player
Показать описание
Multiply two polynomials
3.7
Given two polynomials represented by two arrays, write a function that multiplies given two polynomials.

Input: A[] = {5, 0, 10, 6}
B[] = {1, 2, 4}
Output: prod[] = {5, 10, 30, 26, 52, 24}

The first input array represents "5 + 0x^1 + 10x^2 + 6x^3"
The second array represents "1 + 2x^1 + 4x^2"
And Output is "5 + 10x^1 + 30x^2 + 26x^3 + 52x^4 + 24x^5"
Рекомендации по теме
Комментарии
Автор

bro how to create polynomial equation?

PolisettySaichandrasekhar
Автор

how if we want to add, remove and insert??

nurilhidayah