<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def genOutputs(self, code, match):
 """Return a list out template outputs based on the triggers found in the code and the template they create. """


        out = sorted((k, match.output(m)) for (k, m) in
                     self.collectTriggers(match.match, code).items())
        out = list(map(lambda a: a[1], out))
        return out