Question: I compile my java code on command prompt using javac Assign1.java Domino.java DominoGroup.java It compiles and it creates my three .class files, but then when

I compile my java code on command prompt using javac Assign1.java Domino.java DominoGroup.java

It compiles and it creates my three .class files, but then when I try to run my program with java Assign1

I get this error

Error: Could not find or load main class Assign1 Caused by: java.lang.NoClassDefFoundError: assign1/Assign1 (wrong name: Assign1)

Am I doint something wrong? Can someone help me correct whatever error I am making.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!