how to take input in python in a line one below other code example Example: taking input of n integers in single line python in a list arr = list(map(int, input().split()))