Given a grid where 0 is an open cell and 1 is a wall, and given source and destination cells [r, c], determine whether there is a path from source to destination moving 4-directionally through open cells only. Return true or false. The input is JSON {grid, source, destination}.
Input: JSON {grid, source, destination}.
Output: Boolean — true or false.
Input: {"grid":[[0,0,0],[1,1,0],[0,0,0]],"source":[0,0],"destination":[2,2]}
Output: true
Explanation: A clear path exists.Input: {"grid":[[0,1],[1,0]],"source":[0,0],"destination":[1,1]}
Output: false
Explanation: Blocked by walls.Input: {"grid":[[0]],"source":[0,0],"destination":[0,0]}
Output: true
Explanation: Same cell.1<=rows,cols<=300