"Java Objects (Retired)" was retired on January 31, 2017. You are now viewing the recommended replacement.

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 Objects (Retired) Meet Objects Welcome Back

Charles Lockhart
Charles Lockhart
5,732 Points

the console won't let me clear the screen like we have learned for some reason?

The console is still in java-repl so I'm not sure if that has anything to do with it. Though, :cls works just fine though

2 Answers

Christopher Augg
Christopher Augg
21,223 Points

Charles,

You can clear the screen while in the java-repl with CTRL-L. However, if you need to get out of the java-repl and compile you can use CTRL-C to terminate it first. Then use the commands you have come to know to clear, compile, and run.

Please let me know if this helps.

Regards,

Chris

Charles Lockhart
Charles Lockhart
5,732 Points

I am using a macbook so I tried using command-c and command-l but it still failed to work. Thanks for the help though

Christopher Augg
Christopher Augg
21,223 Points

Charles,

My apologies for only providing windows CTRL options. On mac you will want to use Control-L to clear when in the java-repl and Control-c to terminate.

Regards,

Chris

Drew Warren
Drew Warren
4,565 Points

Thank you very much Chris for asking this question and Charles for answering it.

I have now started a notepad text document to keep track of the shortcuts and commands for the java-repl.

Thanks again,

Drew