jefsummers provided way to learn definitions of functions you need to use. This is valuable knowledge - how to access built-in help of Python. It takes some practice to develop skills for comprehending information which help provides (and this is what learning is all about).
It seems to me that some examples how to use input() can help in learning process. In interactive interpreter:
It seems to me that some examples how to use input() can help in learning process. In interactive interpreter:
>>> input('What is your name? ') # ask for name What is your name? Bob # input the name 'Bob' # name is displayed but it's gone after that >>> name = input('What is your name? ') # in order to use name later, we assign it to name What is your name? Bob >>> name # now we can use name whenever we need 'Bob' >>> profession = input('What is your profession? ') # let' ask some more and assign What is your profession? The Builder >>> profession 'The Builder' >>> title = f'{name} {profession}' # let's use these values to create new value >>> title 'Bob The Builder'Just keep in mind that input always returns str, so if you want to make calculations conversion is needed.
I'm not 'in'-sane. Indeed, I am so far 'out' of sane that you appear a tiny blip on the distant coast of sanity. Bucky Katt, Get Fuzzy
Da Bishop: There's a dead bishop on the landing. I don't know who keeps bringing them in here. ....but society is to blame.
Da Bishop: There's a dead bishop on the landing. I don't know who keeps bringing them in here. ....but society is to blame.