Basically all I'm trying to do is get the list to sort and display in different ways. But it seems after I do the first print it will get "TypeError: 'int' object is not callable". I'm assuming that's because I'm at the end of the list and need to restart at the beginning? Not sure how to do that or if that's the reason.
##vars
Index = 0
NumSize = 0
NumInput = 0
ManNum = 0
##Asking for list size
NumSize = int(input("How many numbers would you like to enter?:\n====>"))
##Declaring list
Numbers = [0] * NumSize
##Collecting data
for Index in range(NumSize):
NumInput = int(input("Please enter a number:\n====>"))
Numbers[Index] = NumInput
##Getting highest number
MaxNum = max(Numbers)
##Printing list
print("::::The numbers you entered were::::")
for Numbers in Numbers:
print(Numbers)
##Sorting list small to large
Numbers.sort()
print("::::The numbers while sorted::::")
for Numbers in Numbers:
print(Numbers)
##Sorting list large to small
Numbers.reverse()
print("::::The numbers reversed::::")
for Numbers in Numbers:
print(Numbers)
##Printing largest number
print("::::Largest number::::\n",
MaxNum)