diff options
author | Marcel Ribeiro Dantas <ribeirodantasdm@gmail.com> | 2022-06-27 00:28:16 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-27 00:28:16 +0200 |
commit | 5d133e847846b4c8d436f7a567674c2e1df35a13 (patch) | |
tree | 7ebc7704f02ceef195a8896a80a06ed81cc12585 /kotlin.html.markdown | |
parent | 27f7f03401ff747a61a912fdf73549b1788b13e1 (diff) | |
parent | 8f28c8021b8ce3cb791861ad19c41e12228d8bcd (diff) |
Merge branch 'master' into patch-1
Diffstat (limited to 'kotlin.html.markdown')
-rw-r--r-- | kotlin.html.markdown | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/kotlin.html.markdown b/kotlin.html.markdown index 5bbf6847..12008074 100644 --- a/kotlin.html.markdown +++ b/kotlin.html.markdown @@ -180,7 +180,7 @@ fun helloWorld(val name : String) { // destructuring in "for" loop for ((a, b, c) in listOf(fooData)) { - println("$a $b $c") // => 1 100 4 + println("$a $b $c") // => 1 2 4 } val mapData = mapOf("a" to 1, "b" to 2) @@ -426,7 +426,7 @@ data class Counter(var value: Int) { operator fun invoke() = println("The value of the counter is $value") } -/* You can also overload operators through an extension methods */ +/* You can also overload operators through extension methods */ // overload -Counter operator fun Counter.unaryMinus() = Counter(-this.value) |