Adventure Game
A cave consists of rooms connected through tunnels reached via doors.
Rooms are numbered starting at 1.
Each room has at most three doors.
Doors are numbered starting at 1.
The player moves from room-to-room.
There is a demon that moves from room-to-room on its own.
Player and demon start in random rooms.
If the player and the demon are in the same room, the player is captured and the game ends.
Input:
- (1) Cave definition
- (2) Player commands to move