Last active
August 27, 2015 02:36
-
-
Save rpearce/e6455f67ecfddadee780 to your computer and use it in GitHub Desktop.
Songs Map Challenge
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
songs = [ | |
{ | |
id: 1, | |
title: "Mother", | |
author: "Pink Floyd", | |
album: "The Wall" | |
}, | |
{ | |
id: 2, | |
title: "Since I've been Loving You", | |
author: "Led Zeppelin", | |
album: "Led Zeppelin III" | |
}, | |
{ | |
id: 3, | |
title: "Re: Stacks", | |
author: "Bon Iver", | |
album: "For Emma, Forever Ago" | |
}, | |
{ | |
id: 4, | |
title: "Von", | |
author: "Sigur Rós", | |
album: "Hvarf-Heim" | |
} | |
] | |
# Write code that will use the `songs` hash | |
# and return an array of hashes containing | |
# only `id` and `title`. | |
# The return value should be this: | |
# [{ id: 1, title: "Mother" }, { id: 2, title: "Since I've been Loving You" }, { id: 3, title: "Re: Stacks" }, { id: 4, title: "Von" }] | |
# | |
# your code here |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment