@Prasad: The number with 22 1s, 1,111,111,111,111,111,111,111, is divisible by 23. The quotient is 48,309,178,743,961,352,657.
Dave On Oct 11, 5:00 pm, prasad jondhale <[email protected]> wrote: > 23 has 3 in its unit place but it is not multiple of 111 or 11 or 1111. > will u pls elaborate on the problem statement? > > On Mon, Oct 10, 2011 at 2:17 PM, anshu mishra > <[email protected]>wrote: > > > > > > > string all1Multiple(int x) > > { > > string s; > > set<int> mySet; > > mySet.push(0); > > int psize, r=1; > > do > > { > > psize = mySet.size(); > > s += '1'; > > r = r % x; > > mySet.push(r); > > r = r * 10 + 1; > > } while(mySet.size() > psize); > > > if (r != 1) return "not Possible"; > > return s; > > > } > > > -- > > You received this message because you are subscribed to the Google Groups > > "Algorithm Geeks" 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/algogeeks?hl=en. > > -- > > Thanks & Regards > Prasad Y.Jondhale > M.Tech(software engg.), > Delhi College Of Engineering, > Main Bawana road,Delhi-110042 > Ph-09540208001 -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" 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/algogeeks?hl=en.
