PAT 1009 多项式乘法
1009 Product of Polynomials This time, you are supposed to find A×B where A and B are two polynomials. 这次,你需要找到两个多项式 A 和 B 的乘积。 Input Specification: Each input file contains one test case. Each case occupies 2 lines, and each line contains the information of a polynomial: K\quad N_1\quad a_{N1}\quad N_2\quad a_{N2}\quad...\quad N_K\quad a_{NK} where K is the number of nonzero terms in the polynomial, N_i and a_{Ni} (i=1,2,⋯,K) are the exponents and coefficients, respectively. It is given that $....