Sokoban Level 2a

From NetHackWiki
Revision as of 20:59, 1 March 2009 by 72.76.253.32 (talk) (Strategy: - fixed error in section 4 that makes boulder A immovable)
Jump to navigation Jump to search

This level of sokoban is often considered one of the hardest levels of the 8. There are 16 boulders and 12 pits.

0 boulder
^ pit
@ starting position/downstairs
< upstairs
 ----          -----------
--.@--------   |.........|
|..........|   |.........|
|.0-----0-.|   |.........|
|..|...|.0.|   |....<....|
|.0.0....0-|   |.........|
|.0..0..|..|   |.........|
|.----0.--.|   |.........|
|..0...0.|.--  |.........|
|.---0-...0.------------+|
|...|..0-.0.^^^^^^^^^^^^.|
|..0......----------------
-----..|..|
    -------


Strategy

The following solution solves the level without putting any blocks in an immobile position. Faster solutions which do not necessarily leave every boulder free might exist.

All boulders are replaced by letters so they can be referred to. Moving the boulders is shortened to r for right, l for left, u for up, d for down. An asterisk is used to denote the last move filled a pit (and thus removed the boulder from the game). So N ddrr* means move boulder N two times down and two times to the right into a pit.

Make some room in the bottom:

 ----          ----------- P rrru
--.@--------   |.........| O rr*
|..........|   |.........| N dlll ll
|.A-----B-.|   |.........|
|..|...|.C.|   |....<....|
|.D.E....F-|   |.........|
|.G..H..|..|   |.........|
|.----I.--.|   |.........|
|..J...K.|.--  |.........|
|.---L-...M.------------+|
|...|..N-.0.^^^^^^^^^^^^.|
|..P......----------------
-----..|..|
    -------

Create a pathway in the upper right:

 ----          ----------- B dd
--.@--------   |.........| C l
|..........|   |.........| M l
|.A-----B-.|   |.........| F u
|..|...|.C.|   |....<....| B ll
|.D.E....F-|   |.........| K d
|.G..H..|..|   |.........|
|.----I.--.|   |.........|
|..J...K.|.--  |.........|
|.---L-...M.------------+|
|...|.P.-....^^^^^^^^^^^.|
|.N.......----------------
-----..|..|
    -------

Clear the lower half, using the 'loop' above M and the 2x3 turning space in the lower right. (Notice how the end always is 'lllrrrrrrruurdrrrrrr*', with the amount of 'r' depending on the amount of filled pits.)

 ----          ----------- M rdrr r*
--.@--------   |.........| N rrrr rrru urdr rrr*
|..........|   |.........| K ddll lllr rrrr rruu rdrr rrr*
|.A-----.-.|   |.........| L ddll lrrr rrrr uurd rrrr rr*
|..|...|CF.|   |....<....| P rdrr uurd rrrr rrr*
|.D.E.B...-|   |.........| I drdd drru urdr rrrr rrr*
|.G..H..|..|   |.........|
|.----I.--.|   |.........|
|..J.....|.--  |.........|
|.---L-K.M..------------+|
|...|.P.-....^^^^^^^^^^^.|
|.N.......----------------
-----..|..|
    -------

Now it depends on whether you want to be able to have all the boulders freely moving after you finish the level. In this solution all boulders can be moved freely. Create a pathway on the right, enter the middle room and remove boulder B and restore pathway in the left:

 ----          ----------- C d
--.@--------   |.........| F l
|..........|   |.........| G r
|.A-----.-.|   |.........| D u
|..|...|CF.|   |....<....| E r
|.D.E.B...-|   |.........| B ddd
|.G..H..|..|   |.........| D d
|.----..--.|   |.........| A d
|..J.....|.--  |.........|
|.---.-.....------------+|
|...|...-..........^^^^^.|
|.........----------------
-----..|..|
    -------

Use the large loop around the entire level to clean more boulders:

 ----          ----------- B rddd rruu rdrr rrrr rrr*
--.@--------   |.........| J rrrr dddr ruur drrr rrrr rrr*
|..........|   |.........| E rddd rddd rruu rdrr rrrr rrrr r*
|.A-----.-.|   |.........| H rrdd dddr ruur drrr rrrr rrrr r*
|..|...|F..|   |....<....| G rrrr dddd drru urdr rrrr rrrr rrrr *
|.D..E..C.-|   |.........|
|..G.H..|..|   |.........|
|.----..--.|   |.........|
|..J..B..|.--  |.........|
|.---.-.....------------+|
|...|...-..........^^^^^.|
|.........----------------
-----..|..|
    -------

The level is now finished:

 ----          -----------
--.@--------   |.........|
|..........|   |.........|
|.A-----.-.|   |.........|
|..|...|F..|   |....<....|
|.D.....C.-|   |.........|
|.......|..|   |.........|
|.----..--.|   |.........|
|........|.--  |.........|
|.---.-.....------------+|
|...|...-................|
|.........----------------
-----..|..|
    -------

Next level

After this level, you will face either of the following levels:

Sokoban Level 3a
  --------
---.|....|
|...0....|----------
|.-.00-00|.|.......|
|.00-......|.......|
|.-..0.|...|.......|
|....-0--0-|...<...|
|..00..0...|.......|
|.--...|...|.......|
|....-0|---|.......|
---..0.-----------+|
  |..0@^^^^^^^^^^^.|
  ------------------
Sokoban Level 3b
--------------------
|........|...|.....|
|.00..-00|.-.|.....|
|..|.0.0.|00.|.....|
|-.|..-..|.-.|..<..|
|...--.......|.....|
|...|.0.-...-|.....|
|.0.|0.|...--|.....|
|-0.|..-----------+|
|..0....^^^^^^^^^^.|
|...|.@-------------
--------