Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialRoger Green
643 PointsConfused
Let's create a dictionary that contains the currencies of the various countries along with their country codes. The country code will be the key and the currency the value. Using the following key-value pairs: US : Dollar, UK : Pound, JP : Yen assign them to a constant named currencies.
let currencies["US": "Dollars", "UK": "Pound", "JP", "Yen"]
4 Answers
David Curtis
11,301 Pointsit should be "JP": "Yen". you have "JP", "Yen".
Valentin Rosu
9,217 Pointslet currencies = ["US": "Dollar", "UK": "Pound", "JP": "Yen"]
Roger Green
643 PointsI feel so stupid lmao
Aimee Ault
29,193 PointsIt's a very easy mistake to make and especially miss, no need to feel stupid :)
David Curtis
11,301 Pointshaha - hey man, i do this for a living. these types of bugs happen all the time! :D
Kelvin Atawura
Front End Web Development Techdegree Student 19,022 Pointshey David Curtis was hoping if you can help me with the extra credit question,please. it read: "Create an array of 10 songs where each song is a dictionary. The dictionary contains the following keys: title, artist and album." But confused about it because all the keys in the example took one value. can a key take on more values? and if so how would the syntax look like please?
Mohammed Ali Zaheer
11,787 PointsMohammed Ali Zaheer
11,787 Pointsyou also forgot = sign