import java.applet.Applet;  // java applet sinifini cagir
import java.awt.*;          // java pencere kullanma sinifini cagir

import java.io.*;

class metotornegi3a
{
    // sayinin karesi dinamik metodu
    public double kare(double x)
    {
    return x*x;
    }
}

public class metotornegi3 extends Applet 
{
    double sayi=5;           // Gercek degisken sayi
    metotornegi3a nesne1=new metotornegi3a(); 
    public void paint(Graphics g) 
    {
    g.drawString(sayi+"nin karesi =  "+nesne1.kare(sayi),25,50);
    }
}
