I can’t seem to figure out where I am going wrong. The code is very similar to the hints yet it doesn’t give me the expected output of initial w.
Without the unnecessary additional numbers I added in the code, I get a very large number for initial w.
I’m a beginner at python and help would be appreciated

I have similar problem in the 2nd exercise (compute gradient). I tried everything but it’s not returning the expected values. Please check below screenshots and advise where I’m doing wrong. Thanks

Hello Muzaffar - Take a close look at where in the loop you are reducing the partial differentials by a factor of m. It looks like you are reducing the sum each time around the loop (for i in range(m)). It’s okay (but I believe inefficient) to reduce the ith partial differential by m and add that to the running totals (dj_dw) and (dj_db) but it’s incorrect to add it to the running totals and then divide by m. If you delay dividing by m there’s a more efficient way. Hope this helps.