http://www.cplusplus.com/reference/clibrary/cmath/pow/ http://www.cppreference.com/wiki/c/math/pow
See if these links help. You can write a program that compares the values given by the pow function and your iterative function. As you know your iterative function is correct, you can probably narrow down the range where pow () does not work. On Sep 14, 10:19 am, vaibhav <[email protected]> wrote: > In this problem I used the pow function (present in math.h library of > c++).It got accepted for small test case but gave me wrong answer for > the large test case.When I later changed the program and used the > iterative method and calculated powers iteartively rather then using > the inbuilt pow function the answer was correct.when I compared the > files the difference between the answers varied from 1-20. I couldnt > qualify only due to this error. > > Can someone please through some light on this working of pow function. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "google-codejam" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/google-code?hl=en -~----------~----~----~----~------~----~------~--~---
