+ 1
What is wrong in this Python code?
mop=input() pop=mop[::-1] print(pop) def is_prime(n): if n < 2: return False for i in range(2, int(n ** .5) + 1): if n % i == 0: return False return True plop="mop, pop".split(" ,") P = [int(i) for i in plop if is_prime(int(i))] print(num_list) print(len(num_list)==2)
4 Réponses
+ 7
Bithi D what is the output supposed to be?
+ 6
is it a joke?
https://code.sololearn.com/c8b56BU1gWn4/?ref=app
just redo all the indents
+ 1
mop=input()
pop=mop[::-1]
print(pop)
def is_prime(n):
if n < 2:
return False
for i in range(2, int(n ** .5) + 1):
if n % i == 0:
return False
return True
plop="mop, pop".split(" ,")
P = [int(i) for i in plop if is_prime(int(i))]
print(num_list)
print(len(num_list)==2)
Why still error?
+ 1
It is supposed to be if the input is an emirph number.