Hello @abdulilah_alkhalaf,
Besides taking general courses, since you can open the lab, I suggest you to
-
do
print(variable)andprint(type(variable))to inspect the content and the type of any variable not clear to you -
From the import lines, we know public libraries
numpyandmatplotlibare used and they are abbreviated asnpandpltrespectively. If you see any method name starting withnp.andplt., then please google the full method name (e.g. google np.exp) for more examples and explanations. -
After reading the explanations and examples found by googling, hopefully you would have some ideas about the method, and then I strongly suggest you to verify your ideas by trying the methods out. You may do so by adding lines like
print(np.exp(2))to use the method and print the result for inspection. Please remove any of these additional lines after you are done because they may interfere with the grader.
It’s important to try things yourself as you are learning, and I think it is the same for both beginners and experienced learners, especially in this self-learning era. Lastly, this post has some relevant information about learning and practicing Python.
Cheers,
Raymond