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

Declare a variable that is named the camel-cased version of "first name". Store the user's first name into this new vari

I want to know how to do in the workspace practically in a step by step process from scratch

IO.java
// I have imported java.io.Console for you.  It is a variable called console.
Public Class Introductions {
  Public Static Void main (String[] args); {

  Console console =System.console();

  String firstName = console.readline('please enter your name','firstNmae');

  javac Introductions,java;
  java Introductions;

2 Answers

Kenzo Qui
Kenzo Qui
2,350 Points

Hi, you could change the single quotes into double quotes and remove that thing from ',' to Nmae' It should look something like this String firstName = console.readline("Please enter your name: "); Also, remove the unnecessary use of the java compiler and the java execution command. You use that on the command line of java. This test does it invisibly in the background do remove that.

Thanks Kenzo Qui for the help! Great work!