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 multiple format strings

i dont get it. it says to "Create a new variable called name and accept input from the console using the readLine method."

I did "String name = console.readLine();"

i take input and store is in name variable but it not working???

2 Answers

Hey Jean,

Welcome to treehouse!

I tried what you were doing and was temporarily confused as well but what you have to do is pass in text inside the input field. So for example

String name = console.readLine("What is your name?");

This occurs again in the next stage as well but now that you saw the above, you should be able to do it no problem.

Happy Coding!

Kevin

it works!! thanks

thanks