import java.io.*;
import javax.swing.*;
 
class H13Ex1a
{
     public static void main (String args[]) throws IOException
     {
	    double xi[]=new double[500];
        double yi[]=new double[500];
        String dosyaismi=JOptionPane.showInputDialog("Dosya ismini giriniz : ");
        int i=-1;
        try{
	    DataInputStream fin=new DataInputStream(new FileInputStream(dosyaismi));
        try {
        while(fin != null)
        {
        i++;
        xi[i]=fin.readDouble();
        yi[i]=fin.readDouble();
        System.out.println(xi[i]+yi[i]);
        }
        } catch(EOFException e_eof) {System.err.println("dosyada veri bitti"); }
        }catch(IOException e_io) {System.err.println("dosya bulunamadư"); }      
     Plot pp=new Plot(xi,yi);
     pp.plot();
     }
}
