You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The exercise expects one to understand fib sequence generation algorithm, but not the function "return" mechanism...
I'd propose to take some other example:
defsign(x):
""" function returns the sign of number: 1 if positive, -1 if negative, or 0 ps.: return exits fuction, so no further actions happen after it occurs """ifx>0:
return1# placeholder "return 1"ifx<0:
return-1# placeholder "return"return0# placeholder "0"
The text was updated successfully, but these errors were encountered:
dz0
changed the title
Functions/return val (Lesson 7 Task 3) iexercise is not to the point
Functions/return val (Lesson 7 Task 3) exercise is not to the point
Dec 23, 2016
The exercise expects one to understand fib sequence generation algorithm, but not the function "return" mechanism...
I'd propose to take some other example:
https://github.com/JetBrains/pycharm-courses/blob/master/introduction_course_v2/lesson7/task3/return_keyword.py
The text was updated successfully, but these errors were encountered: