when grid[i][j] == -b_nums, it means that grid[i][j] are already visited from all b_nums ...
it will give you a maximum flow. This version use BFS to search path. Assume the first is the source and the last is the sink.