
def print_agenda(events, sport):
    print 'AGENDA'
    print '======'
    print ''

    for event in events:
        if sport is not None and sport != event.sport:
            continue

        print '* [{}] - {} - {} - [{}]'.format(
            event.date.strftime('%c'),
            event.sport,
            event.event,
            ', '.join(['av{}'.format(channel) for channel in event.channels])
        )