#!/usr/bin/env python3 import sys with open("result") as f: content = f.readlines() content = [x.strip() for x in content] with open("tests.h") as f: tests = f.readlines() tests = [x.strip() for x in tests] for test in content[-1][2:].split(" "): if test.startswith("-"): continue print (tests[int(test)-1])