I have one little problem with my python knowledge (novice ). The thing I'm trying to do is input list of strings to variable and then I'll need to do some for looping over the list and return few strings from list.
The problem is that I don't know how to input a list to variable.
Here's a code how I tried:
x=[]
x=(input('Please enter a list of strings: '))
...and then I entered ['car', 'house', 't-shirt', 'bicycle', 'images']
assuming that x
will be a variable with list of strings but it's not.
Please help. Thx!