diff --git a/wizard-work/spark/check_result.py b/wizard-work/spark/check_result.py new file mode 100644 index 0000000..c9d0c40 --- /dev/null +++ b/wizard-work/spark/check_result.py @@ -0,0 +1,13 @@ +#!/usr/bin/env python3 +"""Check that factorial(7) equals 5040.""" +import sys +sys.path.insert(0, '/root/.hermes/wizard-outputs/spark') +from verify_check import factorial + +result = factorial(7) +expected = 5040 +if result != expected: + print(f"FAIL: factorial(7) = {result}, expected {expected}", file=sys.stderr) + sys.exit(1) +print(f"PASS: factorial(7) = {result}") +sys.exit(0) \ No newline at end of file