I've got a python script for automating a task. But every time I run it, it asks for input to provide. So for instance when I run the following command:
$ python icecream.py
Which flavor do you want to choose?
1. Blueberry
2. Vanilla
What I want to know is that how can I provide pre-input to the script if I like the vanilla flavor. Can I use a flag like python icecream.py -1
. I'm a beginner at this, so please tolerate if I'm doing anything wrong.