Почему ошибка в коде: "ValueError: invalid literal for int() with base 10: 'Glory'"

    filei=open("Input.txt",'r')
num = list(map(int, filei.read().split()))//Ошибку связывает именно с этой строчкой кода 
countp = 0
countn = 0
for number in num:
    if num >= 0:
        countp = countp + 1
    else:
        countn = countn + 1

pairedcount = 0
notpairedcount = 0
maxnumber = float("-inf")
minnumber = float("inf")
for number in num:
            if number % 2 == 0:
                pairedcount = pairedcount+ 1
            else:
                notpairedcount=notpairedcount+ 1
            if number > maxnumber:
                maxnumber = number
            if number < minnumber:
                minnumber = number

fileout=open("output.txt",'w')
fileout.write("Number of positive numbers:")
fileout.close()
fileout=open("output.txt",'a')
fileout.write(str(countp))
fileout.close()
fileout=open("output.txt",'a')
fileout.write("\n""Number of negative numbers:")
fileout.close()
fileout=open("output.txt",'a')
fileout.write(str(countn))
fileout.close()
fileout=open("output.txt",'a')
fileout.write("\n""Number of paired numbers:")
fileout.close()
fileout=open("output.txt",'a')
fileout.write(str(pairedcount))
fileout.close()
fileout=open("output.txt",'a')
fileout.write("\n""Number of not paired numbers:")
fileout.close()
fileout=open("output.txt",'a')
fileout.write(str(notpairedcount))
fileout.close()
fileout=open("output.txt",'a')
fileout.write("\n""Maximum number:")
fileout.close()
fileout.write(str(maxnumber))
fileout.close()
fileout=open("output.txt",'a')
fileout.write("\n""Minimum number:")
fileout.close()
fileout.write(str(minnumber))
fileout.close()

Ответы (0 шт):