So the goal of this code is to remove duplicates from the input and then print out a list without the duplicates and I think I got it but I can't seem to remember how to take in input with spaces and none of the things I have looked up so far have been very helpful to my case. Here's my code.
def eliminateDuplicates(lst):
strnumbers = str(lst)
listnumbers = list(strnumbers.split())
newlist = []
for number in listnumbers:
if number not in newlist:
newlist.append(number)
return newlist
def main():
numbers = int(input("Enter numbers separated by space"))
print("The distinct numbers are: ", eliminateDuplicates(numbers))
main()