Does it work for 1/17, 2/17, 3/17, etc.? Dave
On Jul 1, 5:23 pm, jalaj jaiswal <jalaj.jaiswa...@gmail.com> wrote: > we are given with Numerator and Denominator. After division we might get a > recurring decimal points float as the answer. > For example 23.34563456 ... > return 3456 i.e the recurring part > > i did it by converting the decimal part into string(itoa).. then a scan to > find the first repeated character ...then outputting the string upto that > location of first character-1 > i found first repeated character using an auxilarry array[0..9].. > total 3 scans.. O(n) > > any better solutions please ?? > -- > > With Regards, > Jalaj Jaiswal > +919026283397 > B.TECH IT > IIIT ALLAHABAD -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to algoge...@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.