Okay, so if I have a hash of hashes to represent books like this:
Books =
{"Harry Potter" => {"Genre" => Fantasy, "Author" => "Rowling"},
"Lord of the Rings" => {"Genre" => Fantasy, "Author" => "Tolkien"}
...
}
Is there any way that I could concisely get an array of all authors in the books hash? (If the same author is listed for multiple books, I would need their name in the array once for each book, so no need to worry about weeding out duplicates) For example, I would like to be able to use it in the following way:
list_authors(insert_expression_that_returns_array_of_authors_here)
Does anyone know how to make this kind of expression? Thanks very much in advance for any help received.