Enum Java Programmer Mock Interview

Master 30 Enum Java Programmer interview questions covering type safety, constant design, and implementation patterns.

WRITTEN BY WILLIAM SWANSEN
QUESTION 10 OF 30

Can a constructor be declared inside Enum in Java?

When you are interviewing for a role with a specific focus, the interviewer's questions may sound similar to each other. Interviewers tend to use similar constructs and formats when creating questions for the interview. Like most people, they follow patterns in their job. Doing this helps interviewers simplify the process of creating the questions and conducting the interview.

It is critically important that you listen very carefully to the interviewer's questions. Since they use similar formats for their questions, you may get confused about what the interviewer is asking you about. Failing to answer the interviewer's question with the information they seek may be interpreted as you not knowing the information rather than not understanding the question. If you are in doubt, it is okay to ask a clarifying question to determine what the interviewer is seeking to learn.

"You can declare a constructor inside of Enum when coding in Java. However, you can only declare a private or package-private constructor inside Enum. Public and other protected constructors are not allowed inside of Enum."

William Swansen
30 QUESTIONS & ANSWERS · ENUM JAVA PROGRAMMER
See membership