[examples] Refactor to `with` syntax.
@@ -13,7 +13,7 @@ K = int(sys.argv[1]) * base
vectorize = int(sys.argv[2])
run_log = int(sys.argv[3])
-env = compiler_gym.make("loop_tool-v0")
+with compiler_gym.make("loop_tool-v0") as env:
env.reset(
benchmark=env.datasets.benchmark(uri="benchmark://loop_tool-v0/{}".format(K)),
action_space="simple",
