How to read two whole variables on the same line?

Asked

Viewed 2,155 times

-1

How to read two integer variables on the same line with Python?

a= int(input())

b = int(input())

1 answer

0


The code below should help:

N, M = [int(x) for x in input().split(" ")]
  • 3

    I would not like to explain a little what happens in this line/ She is correct, ma It can be magical demias for those who asked or oturas people with same doubt.

  • 1

    The point is : "How the code below will help?". You need to explain. You seem to be responding to someone who will understand. However, other users would like to benefit from this answer.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.