each turn, bots bet on the result of a coin flip, heads or tails, with as much points as they want to bet
then, the bots get the results of the last coin flip: how much money people now have, who bet what etc.
then they get to do it again the next turn, taking into account they aren't aiming for money, they're aiming to have the most money
if a bot has -100 points, they win if everyone else has -200 points
also, i was thinking this might be a good place to apply my "many worlds" method of determining the best bot
although it takes a lot to do, relatively, this is a simple one
basically, whichever bot is more likely to end up having the most points wins
it doesn't matter how much above other players they have... except that in the event of a tie, each winning player gets 1/number of tying players for that possibility
i can optimise by having the splits occur during the middle of the game... if it was only 8 turns, i don't get 256*8, i get something a bit smaller, which might be a little bit difficult to calculate
ok so i run bots 2 times on the starting turn, then 4 times on the next turn, then 8 times on the next turn, rather than 256 times on the first turn, 256 at the second turn, 256 third etc.
which will allow a sort of significant optimisation
Exactly duplicating another answer
This specifically came up for me in a king-of-the-hill contest. In particular, this contest had a random component, so replicating a submission could allow one to win by luck.
In general, duplicate submissions are uninteresting, and do not add anything to any ...
Pressure unit conversion
code-golf
In my line of work I often need to convert between four different pressure units: bar, psi, MPa and kgf/cm2.
Challenge
Write a program or function that does the following:
The user enters a value, the original unit and the conversion unit
The program or fu...
CMC: Remove the last character from a string and append the first character to the start hello -> hhell. Assume the input is at least 2 characters long.
CMC: Given a string S and a non-negative integer N, remove the last N characters from S and append the first N characters of S to the start of S: 1 hello -> hhell. 3 hello -> helhe. Assume the input is at least N characters long.
The Old 3DS hardware is strange. For one, it has 3 *diffrent* CPUs, a ARM11, a ARM9, and a ARM7. What's the ARM7 do, you ask? Why it's a Gameboy Advance on a chip. Seriously, why do they need so much backwards compat?
Also games (applications) can at most use 64MB of RAM, but it's age makes that a bit less suprising
Input :
m n : two decimal integers separacted by a space.
Output :
A table in HTML that has m rows and n columns.
For equity purposes, the output code should be properly displayed by Firefox 57 on a Linux machine on http://browsershots.org/
Please feel free to comment if you know a better al...
Magical reasons. The more datatypes i have, the more operations can be avaliable per byte. Of course, i just settled with Numbers, Arrays, and Booleans
I see that you perform one round of all-pairs matchups, but then you weigh the results of that 100 times. Wouldn't that mean a lucky win gets over-weighted?
I have the weirdest Factoria bug. All keystrokes are interpreted by Factorio as the APL character at the key I press, even if I have the APL keyboard layout disabled.
I had to manually rebind nearly every key to the APL equivalent.
Background
If you do much code golfing, you're likely aware of the bitwise XOR operation. Given two integers, it gives another integer with 1s in the bits where the two inputs differ. So, for example, 1010 XOR 0011 = 1001.
It turns out to be very useful in game theory, where it's better known ...
Blackjack, also known as twenty-one, is a comparing card game between yourself and a dealer, where each player in turn competes against the dealer, but players do not play against each other.
Play goes as follows, the dealer deals you a card. The dealer then deals them-self a card, face down. ...
Conway's Battlegrounds
game-of-life king-of-the-hill python
Related
Conway's Battlegrounds will be a mix of PUBG and Conway's Game of Life. In this challenge, you will need to make a Python bot that will play it.
Game rules
The controller, at the beginning of the round, will create a two...
Calculate pH for a Titration
code-golf chemistry
There are quite a few equations for calculating the pH of a solution, each for a different part of the titration. The challenge here will be to decide which one to use to give the pH for the titration of a weak monoprotic acid with a strong bas...