示例#1
0
文件: simul.py 项目: TheBB/simul
def print_matches(list, pre='Modified matches', post='none'):
    print(pre + ':', end='')
    found = False
    for match in list:
        if match.is_modified():
            if found:
                print(',', end='')
            found = True
            print(' ' + match.get_player(0).name + ' ' +\
                  str(match._result[0]) + '-' +\
                  str(match._result[1]) + ' ' +\
                  match.get_player(1).name, end='')
    if found:
        print('')
    else:
        print(' ' + post)
示例#2
0
文件: simul.py 项目: alendit/simul
def print_matches(list, pre='Modified matches', post='none'):
    print(pre + ':', end='')
    found = False
    for match in list:
        if match.is_modified():
            if found:
                print(',', end='')
            found = True
            print(' ' + match.get_player(0).name + ' ' +\
                  str(match._result[0]) + '-' +\
                  str(match._result[1]) + ' ' +\
                  match.get_player(1).name, end='')
    if found:
        print('')
    else:
        print(' ' + post)