Only run main() if program is run directly

Checking that __name__ is "__main__" prevents main() from being run if
this script is imported as a module.
This commit is contained in:
Jeremy Saklad 2021-06-18 15:13:03 -05:00
parent 4808f23a98
commit aee575848b
Signed by: Jeremy Saklad
GPG Key ID: 9CA2149583EDBF84
1 changed files with 2 additions and 1 deletions

View File

@ -2263,4 +2263,5 @@ def main():
print(Solve(*arguments))
if __name__ == '__main__':
main()