# sumfunc6b.py
# Written by Todd Wareham for CS 2500
"""
Given a type of integer (positive non-zero <= 10,000, negative 
 non-zero >= -10,000, all) and the names of one or more files of strings 
 (all of which need not be integers) as command-line arguments, computes 
 and prints the number, total, minimum, and maximum of all integers of the 
 requested type in the specified files.
"""

import sys 
from sumfunc6a import procFile 


if len(sys.argv) < 3:
    print "usage: ", sys.argv[0], " {pos, neg, all} filename1 {filename2, ...}"
    sys.exit(1)

num, sum, min, max = procFile(sys.argv[1], *sys.argv[2:])
print "#int, sum, min , max = ", num, ",", sum, ",", min, ",", max

