Check if the variables captainJackSparrow and pirateJackSparrow point to the same object and print the result using the println() function.
Structural vs referential equality
Referential equality
Report a typo
Write a program in Kotlin
val pirateJackSparrow = Sailor("None")
val captainJackSparrow = Sailor("None")
// put your code here
___
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.
Create a free account to access the full topic
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.