I want to convert a user given string to list of integers.
If i write 12345 i want [1,2,3,4,5]
I am trying this code to achieve it but gives an exception.

```
fun main() {
    println("Enter Number")
    var numberList = readLine().toString().split("").map { it.toInt() }
    println(number)
}

```

This gives a NumberFormatException: For input string: ""

If i remove .map from it and enter 12345 numberList becomes [, 1, 2, 3, 4, 5, ]

But if i change delimiter to " " -with SPACE- and enter two numbers as 12 345 numberList becomes [12, 345]

How can i correct this?