algorithms

Sleeping Beauty Problem Variant

Say, it’s you who is the Sleeping Beauty, awaken and told by the dungeon master:

Here is a fair coin. I will toss it and if it lands head up, your memories will be erased and you will be put to sleep again and then you’ll wake up after some time in this exactly the same scenario.

If the coin lands tails up, however, you’ll get this fair coin to play with as long as you wish. After then, you will be asked for a number. If that number is equal to the number of times you have been awakened like this, you will be freed.

If your number isn’t right, your memories will be erased and you will be put to sleep again and then you’ll wake up after some time in this exactly the same scenario.

What is your strategy to be freed? If not this time, but eventually?

You know that this dungeon master is telling you the truth. So this may be your first time or the second or the Nth time.

What is your best strategy to escape?

Talk about it here:

http://lesswrong.com/r/discussion/lw/pd5/open_thread_august_28_september_3_2017/dwkw

 

 

Advertisements
Standard
algorithms

Create 2314

This is how you create the number 7.

MakeIntVar A
Inc A
Inc A
A=A*A
A=A+A
Dec A

Or

MakeIntVar A
MakeIntVar B
Inc A
Inc B
Shl A, A
Shl A, A
A=A-B

You can do all the basic operations + – * \ and you can shift right and left, and decrease or increase any variable, which you have to “MakeIntVar” first. By doing that, the variable is initialized to zero.

Now, make 2314 with the shortest possible algorithm.

Standard