<Kotlin: Formatting a print output to separate int...
# stackoverflow
u
Kotlin: Formatting a print output to separate integers entered with a comma How do I separate my user input of integers with commas, for example I enter 78 69 25 13. And I want my output to be 78, 69, 25, 13. fun main() { print("Enter your grades: ") while (true) { val studentGrades = readLine() println("Your grades are: ${"%,d".format(studentGrades)}") break } }