<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def msg_box(self, msg, title=None, typ='info'):
 """ Create a message box :param str msg: :param str title: :param str typ: 'info', 'error', 'warning' """

        self.output['msgbox'] = {'type': typ, "title": title or msg[:20], "msg": msg}