Hello everyone,
I am confused regarding one of the review questions from Chapter 02. For example, below the code snippet:
Which statements about the following class are correct? [Choose all that apply]
From this code, I clearly understand that lines 2 and 4 contain compiler errors; so I marked these as correct answers. However, the book suggests line 7 as well, making lines 2,4, and 7 the correct answers.
Why is line 7 also a correct answer if doesn't even get there while running? Also in line 3, fins shouldn't compile since the line of gills contains an error.. I know that it is also in an instance initializer. What I don't get is how the program reaches line 7 with the previous compiler errors?
Is it something that I am not catching regarding the concepts?
Any clarification will be helpful. Thanks in advance!