Create an algorithm in Python that given a number, returns whether the number is prime or not.
11
def is_prime(n):
 if n == 1:
 return False

 for i in range(2,n):
 if n % i == 0:
 return False

 return True

n = 11
print(is_prime(n)) # Output: True