Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|

Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |

Language: Maclaurin Series of Reciprocals
Description Any function or more compactly, Under certain conditions, Often, the Maclaurin series of which facilitates the evaluation of Given the Maclaurin series of a function Input The input consists of a single test case. The first line contains an integer q (0 ≤ k ≤ n - 1) where _{k}p and _{k}q (-100 ≤ _{k}p ≤ 100, 1 ≤ _{k}q ≤ 100) are integers coprime to each other in the form either _{k}p/_{k}q (if qk ≠ 1) or _{k}p (if _{k}q = 1). It is guaranteed that _{k}p_{0} ≠ 0.The given numbers represent the Maclaurin series of some function Output Let the Maclaurin series of 1/ where p and _{k}'q are integers coprime to each other. Output _{k}'n lines each of the form either p/_{k}'q (if _{k}'q ≠ 1) or _{k}'p (if _{k}'q = 1), listing the coefficients of 1, _{k}'x, x^{2}, ... , x^{n-1} in order.Sample Input 10 1/2 -46/3 9/40 61/80 -22/5 -87/41 1/11 -42/5 -4/13 -21/44 Sample Output 2 184/3 169199/90 6223213/108 28611844561/16200 107867589093163/1992600 545525329585163771/328779000 401297234058997162673/7890696000 2398505849871035056778279/1538685720000 882189800570641237196128639/18464228640000 Source |

[Submit] [Go Back] [Status] [Discuss]

All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di

Any problem, Please Contact Administrator