Week3 Programming Exercise Backward Propagation Bug?

Hi everybody,

I am doing the backward propagation exercise, but I have encountered a weird error. When I run the cell it shows a syntax error (see picture) when creating the dictionary “grads”. However, I did not write this code. I tried refreshing the notebook as well as restarting the kernel and rewriting the code myself, but the syntax error would not go away.

Is there anything else I can try to fix this?
Thank you in advance

image

When you get a syntax error at the beginning of a line like that, it means that your previous line is incomplete. You’re probably missing a close paren or close bracket. Note that the notebook editor is syntax aware, so you can click on a paren and it will highlight the matching one. Or not :scream_cat:

When you can’t find a python syntax error, it usually means you’re looking in the wrong place. :grinning:

1 Like

Thank you very much! I did actually miss a bracket but I found it now :sweat_smile: That fixed the problem