taking a input value in a list in single line code example Example: taking input of n integers in single line python in a list arr = list(map(int, input().split()))