how to concatenate in kotlin
fun main() {
var list = listOf("Hello", "World")
var result = list.joinToString("")
print(result)
}
//It will print:
HelloWorld
//This is another way to concatenate in Kotlin!
//Hopefully it helps!
how to concatenate in kotlin
fun main() {
var list = listOf("Hello", "World")
var result = list.joinToString("")
print(result)
}
//It will print:
HelloWorld
//This is another way to concatenate in Kotlin!
//Hopefully it helps!
how to concatenate in kotlin
fun main() {
val a = 11
val b = 10
println("$a is larger than $b.")
println("max variable holds value of a.")
}
//It will output!
11 is larger than 10.
max variable holds value of a.
//You conactenate using the $ symbol and put the var in it!
//Example is $a or $b
//Hopefully it helps!
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us