Dungeon Master(地下城大师)
Description(描述)
-
You are trapped in a 3D dungeon and need to find the quickest way out! The dungeon is composed of unit cubes which may or may not be filled with rock. It takes one minute to move one unit north, south, east, west, up or down. You cannot move diagonally and the maze is surrounded by solid rock on all sides.
Is an escape possible? If yes, how long will it take? -
你被困在3D地下城,需要找到最快的出路!地下城由单位立方体组成,可能填充或不填充岩石。移动一个单位北,南,东,西,上或下需要一分钟。您不能对角移动,迷宫四周都是坚实的岩石。
逃避可能吗?如果是,需要多长时间?
Input(输入)
- The input consists of a number of dungeons. Each dungeon description starts with a line containing three integers L, R and C (all limited to 30 in size).