Answer the question
In order to leave comments, you need to log in
How to split input data into variables?
I need to make the program understand commands, that is: if I enter "search for 15" for example , then a='search' and b='15' It is also desirable that the program understand commands such as 'add to hs' 15' in which case the variables would be a ='add to hs' and b='15'
Answer the question
In order to leave comments, you need to log in
depending on where to enter if you run from the command line, then it may make sense to get confused with sys.argv
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question