Mercurial > hg > cc > cirrus_work
changeset 384:7245d684b0b5 plus
output format now more congenial for subsequent merging
| author | Henry S. Thompson <ht@inf.ed.ac.uk> |
|---|---|
| date | Fri, 12 Jun 2026 16:14:55 +0100 |
| parents | def4c3375b02 |
| children | 615efac7fc09 |
| files | lib/python/cc/ex4.py |
| diffstat | 1 files changed, 4 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/lib/python/cc/ex4.py Thu Jun 11 21:26:09 2026 +0100 +++ b/lib/python/cc/ex4.py Fri Jun 12 16:14:55 2026 +0100 @@ -20,6 +20,8 @@ global d, N, M print("%s with lastmod out of %s in total"%(M, N)) for k,lv in sorted(d.items(), key = lambda i : i[0]): - print(k, ["%s: %d"%(k,v) for k,v in (sorted(lv.items(), key = lambda i : i[1], - reverse = True))][:10]) + print(k,end='\t') + for k,v in sorted(lv.items(), key = lambda i : i[1], reverse = True): + print(v,k,end=';') + print()
