• Boomer Humor Doomergod@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 month ago

    If you scaled it based on the size of the integer you could get that up to 99.9% test accuracy. Like if it’s less than 10 give it 50% odds of returning false, if it’s under 50 give it 10% odds, otherwise return false.

    • Kairos@lemmy.today
      link
      fedilink
      arrow-up
      0
      ·
      1 month ago

      That would make it less accurate. It’s much more likely to return true on not a prime than a prime

      • themusicman@lemmy.world
        link
        fedilink
        arrow-up
        0
        ·
        1 month ago

        Correct. Not are why people are upvoting. If 10% of numbers are prime in a range, and you always guess false, you get 90% right. If you randomly guess true 10% of the time, you get ~80% right.