Skip to content

Instantly share code, notes, and snippets.

View HaipengGuan's full-sized avatar

Haipeng Guan HaipengGuan

View GitHub Profile
@HaipengGuan
HaipengGuan / gist:95eb1ec2ff274d8f19fc9a0055f56771
Last active July 21, 2018 07:32
489. Robot Room Cleaner
/**
* // This is the robot's control interface.
* // You should not implement it, or speculate about its implementation
* interface Robot {
* // Returns true if the cell in front is open and robot moves into the cell.
* // Returns false if the cell in front is blocked and robot stays in the current cell.
* public boolean move();
*
* // Robot will stay in the same cell after calling turnLeft/turnRight.
* // Each turn will be 90 degrees.