Given the following definition of enum Size, select the commented line number(s) in class MyClass, where you can insert the enum definition individually.
(Choose all that apply.).
enum Size {SMALL, MEDIUM, LARGE} class MyClass {//from www. j a va 2 s. c o m // line1 void aMethod() { //line2 } class Inner { //line3 } static class StaticNested{ //line4 } }
a, d
You can't define an enum within a method or a nonstatic inner class.