I got confused in the gradient function

how the gradient function is calculated
what exactly is the movement
whether we are moving row wise first then column or vice-versa

We are moving first by column wise and than for each row wise. This is because first loop iterates over columns and the second loop iterates over all examples. Comments were also there to represent in the code.

Hope this cleared your doubt. :blush:

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.