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

Java Java Basics Getting Started with Java IO

Add a variable to store a user’s last name using console.readLine. Make sure the variable is the camel cased representa

Add a variable to store a user’s first name using console.readLine. Make sure the variable is the camel cased representation of "last name".

IO.java
String lastName = console.readLine("Enter your last name.");

2 Answers

You added lastName when it is looking for firstName. The next task is to do this for the last name.

Steve.

no i want lastname plz

Your code looks fine, then. What error are you getting?

Code looks perfect to me, too. Are you getting an error about task one no longer passing? That's the only thing I can think of and the problem I ran into on this challenge, too.

If that's the problem, just make sure you type in the lastName variable on the next line instead of over the top of your firstName variable.