Created
June 16, 2017 09:50
-
-
Save MericBERBER/1dca8a50fdf758caa0be73c2ec82163d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Base { | |
private void fun() { | |
System.out.println("Base fun"); | |
} | |
} | |
class Derived extends Base { | |
private void fun() { | |
//Mümkün değil. | |
System.out.println("Derived fun"); | |
} | |
public static void main(String[] args) { | |
Base obj = new Derived(); | |
obj.fun(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment