Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Python by (50.2k points)
Can anyone tell me how to take multiple inputs in Python?

1 Answer

0 votes
by (108k points)

For feeding multiple inputs, you can refer to the below code:

x, y = input("Enter a two value: ").split() 

print("Number of boys: ", x) 

print("Number of girls: ", y) 

print() 

The output:

Enter a two value: 2 3

Number of boys:  2

Number of girls:  3

If you are looking for an online course to learn Python, I recommend this Python Certification program by Intellipaat.

Browse Categories

...