Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
# This is not my solution, the snippet is copied from the link below.
def isGoodArray(self, A):
gcd = A[0]
for a in A:
while a:
gcd, a = a, gcd % a
return gcd == 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.