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 trialjamie Macdiarmid
2,048 PointsStuck again.
sundaes= "banana split;hot fudge;cherry;malted;black and white".split(';')
What's wrong?
available = "banana split;hot fudge;cherry;malted;black and white"
sundaes= "banana split;hot fudge;cherry;malted;black and white".split(';')
2 Answers
Afrid Mondal
6,255 PointsYour code seems fine to me. But instead of assigning the string directly use variable. Like...
available = "banana split;hot fudge;cherry;malted;black and white"
sundaes = available.split(';')
Cena Mayo
55,236 PointsHi Jamie,
Your code technically works, but the instructions say: "Use .split() to break the available string apart on the semi-colons (;). Assign this to a new variable sundaes."
They just want you to use the available variable.
So:
available = "banana split;hot fudge;cherry;malted;black and white"
sundaes = available.split(';')
Best, Cena
jamie Macdiarmid
2,048 PointsThanks Cena. I appreciate your time
jamie Macdiarmid
2,048 Pointsjamie Macdiarmid
2,048 PointsThanks Afrid. I appreciate it.