I can see it seems to say that I’m exceeding the limit of 1,000,000 executions. Can someone tell me what constitutes one execution? Is it running a single line of code? Do I need to make a bid within one million lines of code run? This error doesn’t really tell me anything and it’s not clear what I’m violating. I know my code as it stands is going to take a long time to run. This is on Criss Cross.
Each time that it calls
The million-statement limit here is one important way for us to prevent infinite loops, and to keep the simulation time bounded so that it’s fair for other players. But we are trying to let you run a lot of code for Criss-Cross.
Ah but where is the challenge in that? Now we need to invent interesting algorithms that are more efficient.
I would even suggest to add a memory limit, (my browser now hits 1.8gb of memory for certain games) as an extra challenge.
I do wish though that your current number of statements was visible somehow.
tip: I now have a debug for loop with var debug = 1 +1; x100.000 or something to trigger the soft cap (500.000) pop up. That popup does show the current number of your statements, then you can get an indication of how many statements you are using and compare certain code adjustments to see if the the nr of statements used was reduced
Note that it’s currently buggy as well (in Criss-Cross), sometimes the 1.000.000 is reached but nothing happens (your turn will be a no bid). I also get the soft limit (5101010/500000) popup only once, I need to refresh the site to get it again (re-cast doesn’t work).