import math
from public_tests import *
GRADED FUNCTION: basic_sigmoid
def basic_sigmoid(x):
“”"
Compute sigmoid of x.
Arguments:
x -- A scalar
Return:
s -- sigmoid(x)
"""
# (≈ 1 line of code)
# s =
# YOUR CODE STARTS HERE
s = math.exp(x)
# YOUR CODE ENDS HERE
return s
TMosh
May 2, 2023, 5:51am
2
Hi!
Here are some tips for using the discussion forum:
Please don’t post your code.
Please do post a screen capture of any error messages you get.
Python is extremely strict about how indentation is used. That’s how it defines code blocks. For example, if a function definition starts in column 1, then all of the code that is inside the function has to be indented.
ignore that got it - i was related to {edited} the correct one is {edited}
Niraj_Verma:
the correct one is
That’s great. But regarding the not defined error, you have to run all the above cells.
Note: Posting your code is not allowed, so, delete it.
Best,
Saif
so how i can share my queries if i could not share the code ?
i mean how you will understand the issue ?
or you have access of the code from back end ?
You just share your error and mentors will guide you. If we need your code, we will ask you to send us on a private message.
TMosh
May 3, 2023, 5:03am
9
If we see your error messages, we can usually recognize what the mistakes are.
can you help me with below error
TMosh
May 10, 2023, 1:03am
11
When you open the notebook, you have to run all of the cells starting from the top. This is what loads all of the packages.
how to submit your assigment ?
i think i did all the question but this section is not getting updated - may be i am missing something - please suggest
it worked now ; plz ignore above query