inheritence 4


/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package program;

/**
 *
 * @author Administrator
 */
class lingkup{
    String warna="hijau";
    void infoLingkup(){
        String warna="kuning";
        System.out.println("warna pada metode "+warna);
        System.out.println("warna pada class  "+this.warna);
    }
}
public class LingkupVarMobil166 {
    public static void main(String[] args) {
        lingkup linx = new lingkup();
        linx.infoLingkup();
    }

}

0 komentar:

Post a Comment

Twitter Delicious Facebook Digg Stumbleupon Favorites More

 
Design by Free WordPress Themes | Bloggerized by Lasantha - Premium Blogger Themes | SharePoint Demo