There's no '
to remove in the list. When you print a list, since it has no direct string representation, Python shows you its repr
—a string that shows its structure. You have a list with one item, the string 12,33,223
; that's what [user]
does.
You probably want to split the string by commas, like so:
user_list = user_input.split(',')
If you want those to be int
s, you can use a list comprehension:
user_list = [int(number) for number in user_input.split(',')]