New course! Every coder should learn Generative AI!
Try a free lesson+ 1
How can i make array of data from user input
Suppose i want to make array of names and those names are coming from user Eg names=[collection of names here]
1 Answer
+ 12
With python it will work like this:
names = input().split()
If user enters a succesion of white space separated names, the result will be a list containing these names.