Surely Smallester Mouse

Discussion of challenges you have already solved
User avatar
teebee
Posts: 89
Joined: Mon Nov 10, 2008 3:21 pm
Location: Germany

Surely Smallester Mouse

Post by teebee »

Sorry for being late ... ;-)

Is there another solution?:

Code: Select all

00^1+21^<3^<1^3?:-cp
User avatar
teebee
Posts: 89
Joined: Mon Nov 10, 2008 3:21 pm
Location: Germany

Post by teebee »

I solved it with a 19 instructions mouse. However, I am in doubt if this mouse is really worth setting up a new challenge with the usual restrictions ...
User avatar
adum
Posts: 392
Joined: Thu Apr 19, 2007 12:49 pm
Contact:

Post by adum »

i put one up for 19...
tails
Posts: 191
Joined: Tue Jun 10, 2008 7:51 pm
Location: Tokyo

Post by tails »

Hi, my mouse is exactly the same as teebee's.
19... :shock:
User avatar
efe
Posts: 45
Joined: Sun Oct 26, 2008 10:28 am
Location: germany

Post by efe »

@tails & @teebee thats my solution too !
beza1e1
Posts: 2
Joined: Tue Nov 09, 2010 11:33 am
Contact:

Post by beza1e1 »

If two more solved it in 19, then why is teebee still the single solver for Surely Smallesterest Mouse?
User avatar
teebee
Posts: 89
Joined: Mon Nov 10, 2008 3:21 pm
Location: Germany

Post by teebee »

It might need some time to actually solve it with 19 instuctions ... However, I think they refer to the 20 instructions mouse.
harvestsnow
Posts: 8
Joined: Mon Nov 21, 2011 9:15 pm

Post by harvestsnow »

I found the same too.

Out of curiosity, teebee, what is the success rate of your 19 instructions mouse?
I have one that could theoretically pass the tests once in two days, but I'm a bit reluctant about poundering the server.

Code: Select all

10>1>::>p
could also work about once a month...
User avatar
teebee
Posts: 89
Joined: Mon Nov 10, 2008 3:21 pm
Location: Germany

Post by teebee »

harvestsnow wrote:Out of curiosity, teebee, what is the success rate of your 19 instructions mouse?
I have one that could theoretically pass the tests once in two days, but I'm a bit reluctant about poundering the server.
Did you take into account that there is a time penalty of 30s after 20 trials and one of 1h after 200? Nevertheless, my 19 instructions mouse has a success rate of (3/20)**5 ...
harvestsnow
Posts: 8
Joined: Mon Nov 21, 2011 9:15 pm

Post by harvestsnow »

I didn't know about the 1 hour penalty, I based my estimations on 30s/try.

And there is a slightly better 19 solution (roughly (7/40)**5), with a "nop" instruction that I don't know how to drop or use.

Thanks for confirming that this is the expected solution. After all, it's less intensive that the Cavern master.
trofi
Posts: 23
Joined: Mon Oct 14, 2013 7:20 pm

Post by trofi »

My 20-solution involving "nop" instruction:

Code: Select all

00 1+21^<3^<1^3?:-cp
With source code if you are lazy to decode original bytecode:

Code: Select all

; we store max index on stack
    0 ; [ max_ix ]
    0 ; [ ix, max_ix ]

.Lnext:
    nop
    1
    add ; [ ++ix, max_ix ]

    2 ; [ 2, ++ix, max_ix ]

    1
    dup
    peek ; [ m<ix>, 2, ix, max_ix ]

    3
    dup
    peek ; [ m<max_ix>, m<ix>, 2, ix, max_ix ]

    1
    dup
    gotoeq .Lfinish

    cmp ; [<-1, 0, 1>, 2, ix, max_ix ]
    sub

    ; call to '.Lnext - 1' for new max
    ; otherwise to '.Lnext'
    naked c

.Lfinish: ; [ m<max_ix>, m<ix>, 2, ix, max_ix ]
    print
User avatar
Hippo
Posts: 339
Joined: Sat Feb 01, 2014 12:05 am
Location: Praha 5

Post by Hippo »

I have both mentioned solutions, I have submited the faster O(n) rather to O(n^2) solution.
It took me really long time to get rid of >. BTW: The O(n^2) solution does not fail on inputs with a repeated value while O(n) does (when prefix maximum is ambiguous).
harvestsnow wrote:

Code: Select all

10>1>::>p
You have meant

Code: Select all

10<1<::<p
.
User avatar
Hippo
Posts: 339
Joined: Sat Feb 01, 2014 12:05 am
Location: Praha 5

Post by Hippo »

teebee wrote:
harvestsnow wrote:Out of curiosity, teebee, what is the success rate of your 19 instructions mouse?
I have one that could theoretically pass the tests once in two days, but I'm a bit reluctant about poundering the server.
Did you take into account that there is a time penalty of 30s after 20 trials and one of 1h after 200? Nevertheless, my 19 instructions mouse has a success rate of (3/20)**5 ...
Do I understand the penalty system well that (3/20)^5 solution ... which has expected number of attempts roughly 13170 would gain expected 12970 hours of penalties so roughly 1.5 years of penalties?

OK, I have tested the 19 instructin (3/20)^5 solution on already solved levels and it worked well ... but on current challenge ... I got the penalties and now I am already on 1 per hour attempt :) ... and the penalty is after 250 attempts.

Do you know about penalties obtained after 2000 attempts? :)

Maybe this is why there are only 3 lucky solvers out of 25.
AMindForeverVoyaging
Forum Admin
Posts: 496
Joined: Sat May 28, 2011 9:14 am
Location: Germany

Post by AMindForeverVoyaging »

Hippo wrote:Maybe this is why there are only 3 lucky solvers out of 25.
Frankly speaking, the challenge where you need 19 instructions and you need to try ever so often until you get through should not exist.

This is downright silly.
User avatar
Hippo
Posts: 339
Joined: Sat Feb 01, 2014 12:05 am
Location: Praha 5

Post by Hippo »

harvestsnow wrote:I didn't know about the 1 hour penalty, I based my estimations on 30s/try.

And there is a slightly better 19 solution (roughly (7/40)**5), with a "nop" instruction that I don't know how to drop or use.

Thanks for confirming that this is the expected solution. After all, it's less intensive that the Cavern master.
That would reduce expected number of tries to roughly 46%.
Post Reply