comperendinous
  • Member for 7 years, 6 months
  • Last seen more than 7 years ago
awarded
awarded
comment

@PopeyGilbert This is the maths languages' domain, so they're naturally going to have an advantage, as Golfscript, etc. have a more general golfing advantage. I think there are some places where you could choose to draw the line, though. Most leniently, all libraries created before you posted the question are permitted. This would prevent a simple import answer-type submission. You could say standard (no third-party) libraries only, which permits Mathematica, etc. Or, most strictly, you could permit only primitive drawing functions: draw points and lines, but no graph-plotting functions.

comment

Since you disallow library code that directly relates to the task, and that task is essentially to draw a random network graph, isn't use of native graph-drawing functions also disallowed? This restriction is far from well defined.

comment

Save at least another 12 characters by importing randint as r, Image as I, ImageDraw.Draw as D, which, as part of the imports, doesn't count to your score.

comment

Since the resolution only has to be at least 200x200, you could save a few characters (5, I think) by setting x=255 and using it to replace the instances of 200 and 255.

comment

I've edited the question to provide a way of easily verifying conformance with the spirit of the question, but had to invent thresholds. I think they're reasonable but you may want to tweak them, @BetaDecay.

revised

Provide falsifiable check for mutual intelligibility

Loading…
suggested
Approve
revised

Remove brackets around `if` comparison

Loading…
answered
Loading…
comment

You'd also be able to substitute input for raw_input and save 4 characters in Python 3.

answered
Loading…
comment

raw_input pulls from STDIN, but the player history is passed to your program as a command-line argument, which is why you need sys.argv. For the sake of testing, you could just set it manually with sys.argv = ["sadist.py", "0", "5 5 5 5"]. Then you should be able to call player=sys.argv[2].split(). If importing sys really is impossible, for testing you could even drop the dot and call the array sysargv. So long as everything else works and you go back to sys.argv in your submission, it should be fine.

comment

I don't think that raw_input is going to work. sys.argv[2] seems to be the consensus for Python entries. You might also find use for pop, which would allow you to condense thisisme=player[0];player.remove(player[0]) into the simpler thisisme=player.pop(0).

answered
Loading…
comment

This was Straight Shooter's original strategy, before Politically Correct Gunman came along. It'll be interesting to see if S1 does any better than S2, which is about as far from a winning strategy as it can get. There are a few bots which sweep through the numbers to choose a target, so I suppose it's possible the position of the fixed target might influence the outcome.

comment

@MartinBüttner It isn't. That was my point, and the question has now been edited. Remember that "substitute into" has opposite directionality to "replace with": the original is replaced by its replacement, but a replacement is substituted into the original.

comment

May I suggest substituting "traders" into "Greetings fellow businessmen"? Not everyone here is male, and it's more accurate anyway. Traders needn't have a business of their own.

revised

Italicise other bot names

Loading…
1
2 3 4 5