GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — java-coding-problems/src/inheritance/Cat.java at main · jfullstackdev/java-coding-problems Expand file tree/ Copy pathCat.javaMore file actions 28 lines (16 loc) · 474 Bytes / Copy pathCat.javaFile metadata and controls28 lines (16 loc) · 474 Bytes 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 class Cat extends Animal { void meow(){ System.out.print("meow"); } public static void main(String[] args) { Cat mingming = new Cat(); //family is coming from Animal class System.out.print("call from Animal class, family is : `"); System.out.print(mingming.family); System.out.println("`"); //meuw method is from Cat class System.out.print("call from Cat class, method will `"); mingming.meow(); System.out.println("`"); } } |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |