Note that you get a negative value for the cost, which should never happen. One thing to look for is the sort of problems described on this thread. Are you sure that your previous functions passed their tests?
The other thing to note here is that there is some “statefulness” in the way they wrote that training logic. You can’t just run that cell more than once without rerunning some of the previous cells. Try “Kernel → Restart and Clear Output”, “Cell → Run All” and see if that changes your results.