I have a quick question regarding an error message, sincei never saw this one(first post, sry for formating).
Thanks for all the answers in advance
<Below this line, add a link to the EXACT exercise that you are stuck at.>
<In what way does your code behave incorrectly? Include ALL error messages.>
Did you create a function called is_prime? Your code threw a “global name ‘is_prime’ is not defined” error.
<What do you expect to happen instead?>
Since I don’t get the error when running anywhere else besides here, and the function is running like intended. I expected not to get the massage ^^
def is_prim(x): test = 0 if x > 1: for i in range(2, x - 1): if (x % i) == 0: test += 1 else: pass else: test += 1 if test == 0: print ("True") return True else: print ("Flase") return False is_prim(17)