# -*- coding: utf-8 -*-
"""
Created on Mon Feb 22 14:15:00 2021

@author: rmontant
"""
import sys

def main(argv=[__name__]):
    print(argv)
    
    for a in argv[1:] :   
        handle = open(a, 'r')
        all_lines = []
        while True:
            line = handle.readline()
            if len(line) == 0:
                break
            all_lines.append(line)
        handle.close()
        
        print('{:6d}  {:s}'.format(len(all_lines), a))
#--------

if __name__ == '__main__':
    sys.exit(main( sys.argv) )  
#--------
