Once I
have ran the code in optional lab ( I attached the image below), the error has came across


Once I
Run all of the cells every time you open the notebook.
Hi, I’m new so apologies. I also received the same error message. What do you mean by “Run all of the cells every time you open the notebook.”? I did that and received error messages on all code cells. PC
Solved it. I’m assuming you left “import numpy as np” out for us to solve the problem? I’ve never written code before.
Specifically, each cell depends on the state of the notebook via all of the previous cells.
The state of the notebook is not saved when you close your browser.
So when you open the notebook to work on cell N, you must first successfully run cells 1 thru N-1.
No, that is not true. If a notebook uses numpy, it will be imported in Cell 1.
Thanks. I just figured it out. I didn’t run:
In this lab you will make use of:
Still, was a good exercise to figure some of the problems; well, half way. Thanks again. PC