Click the green flag and watch how all the red circles learn the best way to get to the end avoiding the black circles. There will be a point where it has found the perfect route and will keep doing that.