for real numbers N(n<=2000), Find the longest real number array a[1], a[2], ..., a[m] such that the sum and product of that real number array is equal to N: a[1]+a[2]+...+a[m]=a[1].a[2]. ... . a[m] = N
here my code: http://ideone.com/2CsXul but it WA if n>=100
Sorry this is my first time writing blog