Java 定义 char 实例变量

Java Define char Instance Variable

我目前正在做编程入门的考试复习题,我遇到了这个问题。

Define a char instance variable academicLevel to store the academic level for the employee. The possible values for academic levels are in the range A—E (A=associate lecturer, B=lecturer, C=senior lecturer, D=associate professor, E=professor).

而且我不太确定它希望我如何 'define'。就这样?

private char academicLevel;

我相信它要求您定义一个 char 实例,就像您所做的那样,然后实现一些代码(即:开关)来过滤可能的值