Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Basic Fish class wit only name attribute
class Fish {
private var myName = "Default"
def name = myName
def name_= (newName: String) = myName = newName
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment