Last active
January 2, 2018 13:46
-
-
Save pointcom/bdbf29dd80c92388ec97c8f650df584a to your computer and use it in GitHub Desktop.
Ruby 2.5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Customer = Struct.new(:name, :address, keyword_init: true) | |
Customer.new(name: "Dave", address: "123 Main") | |
#=> #<struct Customer name="Dave", address="123 Main"> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment