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 trial![](https://ecs-static.teamtreehouse.com/assets/views/marketing/shared/community-banner-white-47072046c51352fe6a69f5e691ff5700b28bb11d45197d7bdf066d9ea3f72d0c.webp)
![Michael Narvaez](https://secure.gravatar.com/avatar/8db7d2c343b7c4f178110ca8b43a8db4?s=96&d=https%3A%2F%2Fecs-static.teamtreehouse.com%2Fassets%2Fcontent%2Fdefault_avatar-445fbbabfc8dc9188fb5967fe43322ee0c3e0dd1e10f378bf8343784af5a13eb.webp&r=pg)
Michael Narvaez
4,182 PointsIm stuck at: Declare a String variable named bestSport and initialize it to the first element of the sports array. help!
it says: Declare a String variable named bestSport and initialize it to the first element of the sports array.
and all I get is: String[] sports = { "basketball", "baseball', "football" };
please help !
3 Answers
![alex gwartney](https://uploads.teamtreehouse.com/production/profile-photos/2044782/micro_QVE0xYBM.jpg)
alex gwartney
8,849 PointsString[] sports = { "Basketball", "Baseball", "Tennis" };
String bestSport = sports[0];
![Michael Narvaez](https://secure.gravatar.com/avatar/8db7d2c343b7c4f178110ca8b43a8db4?s=96&d=https%3A%2F%2Fecs-static.teamtreehouse.com%2Fassets%2Fcontent%2Fdefault_avatar-445fbbabfc8dc9188fb5967fe43322ee0c3e0dd1e10f378bf8343784af5a13eb.webp&r=pg)
Michael Narvaez
4,182 PointsThanks a lot !! I was misspelling the second part of the code.
![alex gwartney](https://uploads.teamtreehouse.com/production/profile-photos/2044782/micro_QVE0xYBM.jpg)
alex gwartney
8,849 Pointsnot a problem yea i think we have all been there lol especially when you have been working on courses all day.
![Michael Narvaez](https://secure.gravatar.com/avatar/8db7d2c343b7c4f178110ca8b43a8db4?s=96&d=https%3A%2F%2Fecs-static.teamtreehouse.com%2Fassets%2Fcontent%2Fdefault_avatar-445fbbabfc8dc9188fb5967fe43322ee0c3e0dd1e10f378bf8343784af5a13eb.webp&r=pg)
Michael Narvaez
4,182 PointsThis is true !