added for loop to grid prompt

pull/131/head
alanbjohnston 4 years ago committed by GitHub
parent 93a5388933
commit 7bc4e07771
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -28,13 +28,16 @@ if (choice == '2'):
regex = '[A-Za-z]+[A-Za-z]+[0-9]+[0-9]+[A-Za-z]+[A-Za-z]'
grid = input("\nType your 6 character character grid square (i.e. FM29ha): ")
for i in list(range(2)):
if re.search(regex, grid):
print("grid is valid!")
else:
print("grid is not valid!")
grid = ""
grid = input("\nType your 6 character character grid square (i.e. FM29ha): ")
if re.search(regex, grid):
print("grid is valid!")
break
else:
print("grid is not valid!")
grid = ""
elif (choice == '3'):

Loading…
Cancel
Save

Powered by TurnKey Linux.