Nesne Tabanlı Programlama-1 (Güz-2017) Hafta-6

package iste.main; // kendi yerim
import iste.abc.x; // sinifin yeri
//import iste.abc.*;
public class calistir
{
	public static void main(String[] asa)
	{
		System.out.println("Ben Calistir!");
		new x();
	}

}
package iste.abc;
import iste.xyz.x.d; // sinif
//import iste.xyz.x.*;

public class x{
	
	public x()
	{
		System.out.println("Ben X!");
		new d();
	}

}
package iste.xyz.x;
import iste.abc.a.*; // sinif

public class d{

	public d()
	{
		System.out.println("BEN D!");
		new b();
	}

}
package iste.abc.a; // klasor
import iste.xyz.*; // sinif
//import iste.xyz.y;
public class b{

	public b()
	{
		System.out.println("Ben B!");
		//new iste.xyz.y();
		new y();
	}


}
package iste.xyz;
public class y{
	public y()
	{
		System.out.println("BEN Y!");
	}

}

NTP-1 Hafta-6

Share