I have completed an assignment. However, I am unfamiliar with
javac compiler error messages, and can not find an explanation
for the following error message.
> ----------Compilation output--------------------------------------------
> javac Main.java
> classes in application are
> Main.java:class Main
> Main.java:class Envelope
> Letter.java:class Envelope{
> Letter.java:public class Letter {
> ./Letter.java:12: duplicate class: Envelope
> class Student{
> ^
> 1 error
I have no idea what to make of it and would appreciate any explanation
of what I am doing wrong.
The problem is that you have two classes called Envelope.
If they are supposed to be different classes then rename one of them.
If they are supposed to be the same class then put it in is own file, rather than copy + pasting the code every time you need it.