On Page 133 of the 5th Edition, under the section "Defining an Enumeration", it is mentioned that
"
...
New type definitions, including enumerations, must come after our main method and the methods it owns (or in a separate file, as we will do later).
...
"
My understanding is that there is no strict rule about where the enumeration definition should live as long as it has adequate scope. For example, it can be at the class level before the main method?
Thank you!
On Page 133 of the 5th Edition, under the section "Defining an Enumeration", it is mentioned that " ... New type definitions, including enumerations, must come after our main method and the methods it owns (or in a separate file, as we will do later). ... "
My understanding is that there is no strict rule about where the enumeration definition should live as long as it has adequate scope. For example, it can be at the class level before the main method? Thank you!