# Exercise scaffold. Reference implementation is in a separate directory."""GP1: pure expressions -> typed AST -> verified, forward-only bytecode.This is an educational compiler, not a sandbox for hostile programs."""importastimportsysfrom.languageimportinfer,evaluatedefparse(source):raiseNotImplementedError('Implement this contract from the book.')defsimplify(expression):raiseNotImplementedError('Implement this contract from the book.')defcompile_expr(expression):raiseNotImplementedError('Implement this contract from the book.')defverify(code):"""Abstractly execute all acyclic paths; intersect definitely assigned locals."""raiseNotImplementedError('Implement this contract from the book.')defrun(code):raiseNotImplementedError('Implement this contract from the book.')