2017-03-12 02:30:25 +00:00
|
|
|
def grade(random, key):
|
2017-03-17 23:04:48 +00:00
|
|
|
if key.find("hj3-0p9cgfb-ez") != -1:
|
2017-03-12 02:30:25 +00:00
|
|
|
return True, "Correct!"
|
|
|
|
incorrect_txt = 'Wrong. '
|
2017-03-17 23:04:48 +00:00
|
|
|
if key.find("hj3") == -1:
|
2017-03-12 02:30:25 +00:00
|
|
|
incorrect_txt += "Phase 1 failed. "
|
2017-03-17 23:04:48 +00:00
|
|
|
if key.find("-0p9") == -1:
|
2017-03-12 02:30:25 +00:00
|
|
|
incorrect_txt += "Phase 2 failed. "
|
2017-03-17 23:04:48 +00:00
|
|
|
if key.find("cgfb") == -1:
|
2017-03-12 02:30:25 +00:00
|
|
|
incorrect_txt += "Phase 3 failed. "
|
2017-03-17 23:04:48 +00:00
|
|
|
if key.find("-ez") == -1:
|
2017-03-12 02:30:25 +00:00
|
|
|
incorrect_txt += "Phase 4 failed. "
|
|
|
|
return False, incorrect_txt
|