Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
EE Probability on 1st scroll, what do YOU think?
#21
It makes absolutely no sense for there to be a code segment like the one you gave.

There would be a single try_scroll() routine which accepts the scroll's chance of success (in %) and returns pass or fail.
It would have to be in % because there are scrolls (clean slate) with 1% chance of success.
Such a routine (often a macro, actually) typically looks like:
Code:
boolean try_scroll(int success_rate)
{
  return (random_int(100) < success_rate);
}
/* random_int, in typical C style, will return a number between 0 and 99 */

So, no, not too likely they're doing 4/5 or anything of the sort.
Reply


Messages In This Thread
EE Probability on 1st scroll, what do YOU think? - by SaptaZapta - 2011-09-15, 12:58 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)