Skip to main content

deadlock_right

Function deadlock_right 

Source
fn deadlock_right(burrow: &Burrow) -> bool
Expand description

Mirror image situation to deadlock_left where a D amphipod could block others.

For example:

#############
#.......D...#
###.#.#.#A###
  #.#.#.#B#
  #.#.#.#C#
  #.#.#.#D#
  #########

The hallway has room for the top two amphipods but the D prevents the bottom two from returning to their home burrow.