input() returning wrong type

Asked by GZ

In python I can do the following:
> list(input())
> 3,12
which will return this:
[3, 12]

Sadly this doesn't work in Sikuli because the type of the object from the input will be "unicode" which can not be turned into a list of integers easily.

I hope there is an easy solution to this..

Question information

Language:
English Edit question
Status:
Solved
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Solved by:
GZ
Solved:
Last query:
Last reply:
Revision history for this message
GZ (g-zr) said :
#1

Ok, solved it: map(int, [input()][0].split(","))

Revision history for this message
RaiMan (raimund-hocke) said :
#2

uups, to fast for me ;-) and very creative.

I would have answered:
eval(input)

Revision history for this message
GZ (g-zr) said :
#3

Thank you RaiMan! :)