diff --git a/README.md b/README.md index dafc99d..6303c49 100755 --- a/README.md +++ b/README.md @@ -1,7 +1,9 @@ # Kotlin by Example -[![official JetBrains project](https://jb.gg/badges/official-plastic.svg)](https://github.com/JetBrains#jetbrains-on-github) +[![Obsolete JetBrains project](http://jb.gg/badges/obsolete.svg)](https://confluence.jetbrains.com/display/ALL/JetBrains+on+GitHub) -This is sources of [Kotlin Examples](https://play.kotlinlang.org/byExample/overview). +The repository is archived, please refer to [Kotlin Tour](https://kotlinlang.org/docs/kotlin-tour-welcome.html) for up-to-date Kotlin learning materials. + +------------ ### How to make example diff --git a/examples/07_Delegation/01_delegationPattern.md b/examples/07_Delegation/01_delegationPattern.md index 4b5b27e..9f396da 100755 --- a/examples/07_Delegation/01_delegationPattern.md +++ b/examples/07_Delegation/01_delegationPattern.md @@ -7,19 +7,19 @@ interface SoundBehavior { fun makeSound() } -class ScreamBehavior(val n:String): SoundBehavior { // 2 +class ScreamBehavior(val n: String): SoundBehavior { // 2 override fun makeSound() = println("${n.uppercase()} !!!") } -class RockAndRollBehavior(val n:String): SoundBehavior { // 2 +class RockAndRollBehavior(val n: String): SoundBehavior { // 2 override fun makeSound() = println("I'm The King of Rock 'N' Roll: $n") } // Tom Araya is the "singer" of Slayer -class TomAraya(n:String): SoundBehavior by ScreamBehavior(n) // 3 +class TomAraya(n: String): SoundBehavior by ScreamBehavior(n) // 3 // You should know ;) -class ElvisPresley(n:String): SoundBehavior by RockAndRollBehavior(n) // 3 +class ElvisPresley(n: String): SoundBehavior by RockAndRollBehavior(n) // 3 fun main() { val tomAraya = TomAraya("Thrash Metal")