Unexpected Behavior wrt the final modifier
问题 This is my code package alpha ; class A1 { static class A11 { private final // WHAT IS THE EFFECT OF THIS MODIFIER? void fun ( String caller ) { System . out . println ( "A11:\t" + caller ) ; } } static class A12 extends A11 { private void fun ( String caller ) { super . fun ( caller + caller ) ; } } public static void main ( String [ ] args ) { A12 a12 = new A12 ( ) ; a12 . fun ( "Hello" ) ; } } I have found that with or without the final mdifer in A1.A11 the program compiles and runs. I can