Stacked Dozen

From NetHackWiki
Revision as of 17:33, 5 February 2024 by Umbire the Phantom (talk | contribs) (cats, merge from other stacked dozen article)
Jump to navigation Jump to search

This is one of the new possible maps for Sokoban Level 3 in Nethack Fourk and Level 2 in Hack'EM. It has 11 boulders and 10 hole]]s, leaving 1 spare boulder. In the starting position, all the boulders are stacked on top of each other.

---------         ------  0 boulder
|.......|     ----|....-- ^ hole
|.......|    --..--.....| > starting position/downstairs
|...<...|  ---......-.|.| < upstairs
|.......|  |..........|.| + door
|.......|  |..0..-......|
|+------------.....--...|
|.^^^^^^^^^^^...|>......|
-------------------------

Setup

Start by pushing the boulder pile right to push one of the boulders in the pile onto the tile to the right. As long as there are more than one boulder in the pile you will push only one of the boulders from the pile and the rest of the pile will remain.

---------         ------  0 r
|.......|     ----|....--
|.......|    --..--.....|
|...<...|  ---......-.|.|
|.......|  |..........|.|
|.......|  |..0..-......|
|+------------.....--...|
|.^^^^^^^^^^^...|>......|
-------------------------

The solution expects that each step will create a new boulder by following the step above.

---------         ------  1 urrr rrrd r
|.......|     ----|....-- 1 urrr rrru ul
|.......|    --..--.....| 1 urrr rrru
|...<...|  ---......-.|.| 1 urrr rdrr
|.......|  |..........|.| 1 urrr rd
|.......|  |..01.-......| 1 uurr rr
|+------------.....--...|
|.^^^^^^^^^^^...|>......|
-------------------------
---------         ------  a ld
|.......|     ----|....-- b dd
|.......|    --..--.0...| 1 uurr rr
|...<...|  ---.....b-0|.| 1 uurr r
|.......|  |..........|.| 1 uur
|.......|  |..01.-.a.00.| 1 r
|+------------.....--...|
|.^^^^^^^^^^^...|>......|
-------------------------
---------         ------  1 r
|.......|     ----|....-- 1 d
|.......|    --..--.0...|
|...<...|  ---..0.00-0|.|
|.......|  |..........|.|
|.......|  |..1..-.0.00.|
|+------------....0--...|
|.^^^^^^^^^^^...|>......|
-------------------------

Strategy

First move the boulders from the stack to the position below. Then the boulders can be cleared as follows:

---------         ------   B u
|.......|     ----|....--  A l
|.......|    --..--.G...|  C dll
|...<...|  ---..D.EF-H|.|  A rddl ll
|.......|  |..........|.|  B lddd llll
|.......|  |..AB.-.J.KL.|  D dlld ddll lll
|+------------C...I--...|
|.^^^^^^^^^^^...|>......|
-------------------------
---------         ------   F u
|.......|     ----|....--  E llld ddld llll ll
|.......|    --..--.G...|  I uull lldd dlll llll
|...<...|  ---....EF-H|.|  J lull lldd dlll llll l
|.......|  |..........|.|  F ddll llld ddll llll lll
|.......|  |.....-.J.KL.|  G lddl llll dddl llll llll l
|+------------....I--...|
|.^^^^^^^.......|>......|
-------------------------
---------         ------   H ulld dlll lldd dlll llll llll
|.......|     ----|....--  K d
|.......|    --..--.....|  L llll ulll lddd llll llll llll
|...<...|  ---......-H|.|
|.......|  |..........|.|
|.......|  |.....-...KL.|
|+------------.....--...|
|.^^............|>......|
-------------------------

Alternate setup

Alternately, start by pushing a boulder from the stack 0, with all but the two last boulders being pushed to the right:

---------         ------   0 ruur rrru → I
|.......|     ----|....--  0 rurr rrrr uu → J
|.......|    --..--.....|  0 rurr rrrr dd → H
|...<...|  ---......-.|.|  0 rurr rrrr dr → G
|.......|  |..........|.|  0 rurr rrrr → K
|.......|  |..0..-......|  0 rurr rrr → L
-+------------.....--...|  0 ruur rr → E
|.^^^^^^^^^^^...|>......|
-------------------------

Now to the trickier second half, where we can't push all boulders directly to their resting place:

---------         ------   0 rurd → F
|.......|     ----|....--  0 ruur → C
|.......|    --..--I.J..|  0 r → D
|...<...|  ---....E.-.|.|  C d
|.......|  |........LK|.|  D uur
|.......|  |..0..-....G.|  C r
-+------------.....--H..|
|.^^^^^^^^^^^...|>......|
-------------------------

The penultimate one goes to the left:

---------         ------   0 l → B
|.......|     ----|....--  0A
|.......|    --..--I.J..|  
|...<...|  ---..D.E.-.|.|  
|.......|  |.....C..LK|.|  
|.......|  |..0.F-....G.|  
-+------------.....--H..|
|.^^^^^^^^^^^...|>......|
-------------------------

Which leaves the spread out positioning:

---------         ------   
|.......|     ----|....--  
|.......|    --..--I.J..|  
|...<...|  ---..D.E.-.|.|  
|.......|  |.....C..LK|.|  
|.......|  |.BA.F-....G.|  
-+------------.....--H..|
|.^^^^^^^^^^^...|>......|
-------------------------

Conquer

Now the hole removal can finally begin by pushing the boulders alphabetically:

---------         ------   A ddll*
|.......|     ----|....--  B rddl l*
|.......|    --..--I.J..|  C llld dlll*
|...<...|  ---..D.E.-.|.|  D dlll ddll ll*
|.......|  |.....C..LK|.|  E lldl lldd llll l*
|.......|  |.BA.F-....G.|  F dlld llll ll*
-+------------.....--H..|  G llll ulll ddll llll l*
|.^^^^^^^^^^^...|>......|  H ulll ulll ddll llll ll*
-------------------------  I dddl ulll ddll llll lll*
                           J lldd dlul lldd llll llll ll*
                           K u
                           L llll lldd llll llll lll*

Which leaves the level completed:

---------         ------   
|.......|     ----|....--  
|.......|    --..--.....|  
|...<...|  ---......-K|.|  
|.......|  |..........|.|  
|.......|  |.....-......|  
-+------------.....--...|
|...............|>......|
-------------------------

Next level