codeguru-il / corewars8086

Core Wars for standard 8086 assembly.
Apache License 2.0
31 stars 19 forks source link

Competition Iterator #11

Open YoavKa opened 9 years ago

YoavKa commented 9 years ago

If you ask the engine to run 100 wars with 4 warriors in a war, instead of running every possible combination of 4 warriors 100 times, it will 100 times run a randomly selected group of 4 warriors - much less than the intended amount of runs. Can be reproduced by putting 4 survivors that only jump to themselves ("Do nothing") and asking the engine to run 1 war with 2 warriors. The problem in the code is in CompetitionIterator (Which seems to me like it isn't finished, there are leftovers from my BinomialIterator) and in Competition@runCompetition.

rmkn85 commented 9 years ago

that's on purpose, since there are too many possible combinations On Feb 24, 2015 2:49 PM, "Yovaayova" notifications@github.com wrote:

If you ask the engine to run 100 wars with 4 warriors in a war, instead of running every possible combination of 4 warriors 100 times, it will 100 times run a randomly selected group of 4 warriors - much less than the intended amount of runs. Can be reproduced by putting 4 survivors that only jump to themselves ("Do nothing") and asking the engine to run 1 war with 2 warriors. The problem in the code is in CompetitionIterator (Which seems to me like it isn't finished, there are leftovers from my BinomialIterator) and in Competition@runCompetition.

— Reply to this email directly or view it on GitHub https://github.com/codeguru-il/corewars8086/issues/11.

YoavKa commented 9 years ago

So many that even one run of every possible combination is not possible? I really think that it hurts the idea of every group running against every other group...

rmkn85 commented 9 years ago

when there are 30+ groups, it is too long On Feb 24, 2015 2:56 PM, "Yovaayova" notifications@github.com wrote:

So many that even one run of every possible combination is not possible? I really think that it hurts the idea of every group running against every other group...

— Reply to this email directly or view it on GitHub https://github.com/codeguru-il/corewars8086/issues/11#issuecomment-75751457 .