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 Data Structures Efficiency! Building the Model

Prasoon Shukla
Prasoon Shukla
3,426 Points

Console error

Getting below on running Kraoke.java

Please help!!!

              enable system assertions                                                                                          
-dsa | -disablesystemassertions                                                                                                 
              disable system assertions                                                                                         
-agentlib:<libname>[=<options>]                                                                                                 
              load native agent library <libname>, e.g. -agentlib:hprof                                                         
              see also, -agentlib:jdwp=help and -agentlib:hprof=help                                                            
-agentpath:<pathname>[=<options>]                                                                                               
              load native agent library by full pathname                                                                        
-javaagent:<jarpath>[=<options>]                                                                                                
              load Java programming language agent, see java.lang.instrument                                                    
-splash:<imagepath>                                                                                                             
              show splash screen with specified image                                                                           

See http://www.oracle.com/technetwork/java/javase/documentation/index.html for more details.

Chris Freeman
Chris Freeman
Treehouse Moderator 68,423 Points

What command are you running before seeing this output?

Prasoon Shukla
Prasoon Shukla
3,426 Points

Hi Chris, I ran && clear javac Karaoke.java && java.

1 Answer

Chris Freeman
MOD
Chris Freeman
Treehouse Moderator 68,423 Points

The && in the command line are to chain commands such that as each one completes successfully the next one will run. The first failing command breaks the chain. To debug which command is failing, run each command separately.

$ clear && javac Karaoke.java && java

is the same as:

$ clear
$ javac Karaoke.java
$ java

When running the last command, you'll see that you left of the name of the file you wish to run:

$ java Karaoke

So the command you want is:

$ clear && javac Karaoke.java && java Karake

Prasoon Shukla
Prasoon Shukla
3,426 Points

Thanks, its working now. Thanks a lot for your detailed explanation.