+ 8

User Input in Kotlin

With the recent addition of Kotlin to the code playground (kind of), I've been interested in learning how to code with it. Having never used Kotlin before and finding Google not very helpful, I was just wondering if there was a way to take user input and possibly convert it to different data types. Thanks in advance!

4th Feb 2018, 4:49 PM
Faisal
Faisal - avatar
5 ответов
+ 5
Kotlin is just a another syntax for Java. So do what you would do in Java: Scanner(System.in)
4th Feb 2018, 5:05 PM
1of3
1of3 - avatar
+ 15
its working only in test version
4th Feb 2018, 7:19 PM
Gaurav Agrawal
Gaurav Agrawal - avatar
+ 2
It doesn't seem to be working for some reason :/ Do you think it may just be an issue with the code playground?
4th Feb 2018, 5:26 PM
Faisal
Faisal - avatar
+ 2
Oh okay, thanks!
4th Feb 2018, 7:22 PM
Faisal
Faisal - avatar
1st Jun 2018, 8:58 PM
Burey
Burey - avatar