Ad
  • Custom User Avatar

    You can use float

  • Custom User Avatar

    Thank you :)

  • Custom User Avatar

    Yes, you need to return string representations of big numbers. Hint: there is a type in Java which can be very useful in this kata.

  • Custom User Avatar

    Thanks for the reply. With that said, are we actually supposed to return the huge number that was expected in the random test case?

  • Custom User Avatar

    Make sure that your calculations are not overflowing. Primorials can be very large even for small values of n.

  • Custom User Avatar

    I'm using Java.

  • Custom User Avatar

    What language?

  • Custom User Avatar

    Can I get any tips here?

    randomTests
    expected:<[199404818685642447922083291260309527846441772302999745553302328941028108779436102085502238462877508744319230123231738086523261173652404950301374197869189533802456328667657116662181193092967160367425479733609408962100219816738274883756540352975458339001726555197372062657899457362272134831946087868983807270392076798482532500745072849852168778951955746347251558198156536278544719374413616908418643314061617497623298068046368412412033037281864508352031193837944181756582659700431987846732081648533787259751577345417840936027319626131623529169383807650551078532827381038783056067321299053109335756208779254800108679951211788188768882891420554726898500108858216512101696815035949207873340258279153230244140967926145214972518796767802793435085467919874762671901405348461557949772551966802375824477413855051891293259380032715694632280223659448104457368599265181296990645207362638962972593771017093268657234021460784766165047335708805149654693726109553707080966803090509677140772376112250270947912752601847977528952393810533753316901205618091650630078355202588558705566885269112287609830871917301666578371288584475167097088907991065949820508882729989264549559371822626295221428664355853032587604763408162306268526792773009281456307191236548754976248201605179452279870021200719195801120424447897488482961001196903715389068093175870]> but was:<[3537790813043963966]>

    How do we output something that is that large of a number...