Skip to content

Commit

Permalink
test(samples): add new samples
Browse files Browse the repository at this point in the history
  • Loading branch information
kotlin-samples-pusher-bot committed Apr 29, 2024
1 parent 996f4c5 commit 465f4d7
Showing 1 changed file with 11 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
fun main() {
val myString = "Kotlin is awesome!"
val destinationArray = CharArray(myString.length)

// Convert the string and store it in the destinationArray:
myString.toCharArray(destinationArray)

for (char in destinationArray) {
print("$char ")
}
}

0 comments on commit 465f4d7

Please sign in to comment.