3 ms·
This is fun an interesting. I tried using an actual random number generator to generate inputs, just to verify with my eyes that, as expected, the computers gu
by jrochkind1 8y ago
This is fun an interesting.
I tried using an actual random number generator to generate inputs, just to verify with my eyes that, as expected, the computers guess rate hovered around 50%, and didn't get more than 5% off usually. (I realize it _could_).
I tried picking a 'random' (knowing surely I'll still have unconcious patterns) number 1-5, and then doing that many lefts, pick another number, that many rights.
That got me a really good percentage (computer was only around 30% right) up to ~40 or so iterations. But didn't last, eventually it got to around 50% or so as usual, and then I started to lose.
It would be interesting, if knowing the algorithm the guesser is using, if you could devise an algorithm to defeat it, and "win" lots of money from the "bank". I mean, I guess, the obvious thing to do, if you had the algorithm the guesser was using, you could just run it on your own past input, and then always pick next whatever the opposite of what it would pick is. It seems like that would have to work, and that it couldn't possibly work, heh. This becomes an interesting illustration of... something or other computer science-wise, it reminds me of Godel Escher Bach or something.
What this whole thing makes me think of is surveillance. Say, in an old detective thing, trying to "lose a tail" by making "random" turns. In our society of increasingly universal surveillance, _plus_ computers analyzing the data (and you don't know the exact algorithms being used)... there's probably no way to "lose the tail".
- dan-robertson 8y agoOne can make the algorithm harder to defeat by making it probabilistic. Eg if it will have some kind of expected next move for you to make, and this probably won’t be “definitely left” or “definitely right”, and then so long as it can get some random source (which you don’t have), it should randomly guess your next move from the probability distribution of your moves. That way it’s guesses can’t win in advance and so it probably won’t be wrong so much, and the problem of beating it becomes harder too. E.g. suppose the algorithm works as follows: 1. Let {l,r} be the numbers of times in the history we have seen a five-letter sequence with a prefix of whatever the four most recently made moves were, and a suffix of {left,right} 2. Pick r randomly between 0 and 1 3. If r > l/(l+r) (or l=r=0), guess the next move is r. You know this is the strategy so if you can calculate l and r and so make the opposite move (randomly even) and win with a probability of r/(l+r), however by making your move, you make l/(l+r) converge towards 1/2 and so your probability of winning goes to 1/2 too. I suspect the best strategy in the long run is to play randomly or to just repeat some longish cycle that includes each length five cycle an equal number of times.