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 trialpittawat Sawatyanon
1,072 PointsDeclare a variable that is named the camel-cased version of "first name". Store the user's first name into this new vari
What is the answer to this one please help. I can't move on Declare a variable that is named the camel-cased version of "first name". Store the user's first name into this new variable using console.readLine.
public class name {
public static void main(String[] args) {
Console console = System.console();
String firstname = console.readLine("What is your name? ");
}
}
1 Answer
Steve Hunter
57,712 PointsHi there,
You need to take the instructions literally. Just declare a variable that is the camel case version of first name. It's one line which you have already written but you missed out the uppercase N
in firstName
.
String firstName = console.readLine("What is your name? ");
Steve.
pittawat Sawatyanon
1,072 Pointspittawat Sawatyanon
1,072 PointsI got it