how do i fix this it keeps saying totnumbers len numvalues typeerror object of type 5151445
How do I fix this it keeps saying totnumbers += len(numValues)
TypeError: object of type 'map' has no len()
#getting file as input
print (“Enter file name”)
file1=input()
#try block
try:
error_to_catch=FileNotFoundError
#catching file not found exception
except NameError:
error_to_catch=IOError
#opening file
fName = open(file1)
#initialising variables
sVal, totnumbers = 0, 0
#loop statement for n values
for line_number, line in enumerate(fName):
numValues = map(int, line.split())
#calculating sum
sVal += sum(numValues)
totnumbers += len(numValues)
#printing results
print (“fileName”,file1)
print (“sum”,sVal)
print (“count:”, totnumbers)
print (“Average:”, 1.0*s/totnumbers)
#min max calculation
a=max(numValues)
b=min(numValues)
r=a-b
print (“maximum”,a)
print (“minimum”,b)
print (“Range”,r)
value=input('would you like to continue:')
if value=='Y':
print (“Enter file name”)
file1=input()
else:
print(“good bye”)