Skip to content

Instantly share code, notes, and snippets.

@sebabelmar
Last active November 24, 2016 00:19
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sebabelmar/e84271b43fa7edf1dca3d6030e735256 to your computer and use it in GitHub Desktop.
Save sebabelmar/e84271b43fa7edf1dca3d6030e735256 to your computer and use it in GitHub Desktop.
# Bikes Factory
b1 = {brand: "scott", year: 2016, color: "red"}
b2 = {brand: "specialized", year: 2016, color: "blue"}
b3 = {brand: "Releigh", year: 2016, color: "white"}
arr = Bike.create_bikes_array([b1, b2, b3])
# arr = [< Instance of Bike 1>, <Instance of Bike 2>, <Instance of Bike 3>]
# Stretch print: ["scott", "specialized", "Releigh"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment