import javax.swing.*;
import java.awt.Graphics;
import java.awt.*;
import java.awt.event.*;
import java.awt.geom.*;
public class writeP extends JPanel
{ //grafik penceresine yazę yazar
 String s[];
 public writeP(String si[])
 {super();
 s=new String[si.length];
 for(int i=0;i<si.length;i++){s[i]=si[i];}
 }
 
 public void paintComponent(Graphics g) 
    {   super.paintComponent(g);
	    Graphics2D g2 = (Graphics2D)g;
        g2.setFont(new Font("Serif",Font.BOLD,24));
        g2.setColor(Color.blue);
        g2.setBackground(Color.yellow);
        for(int i=0;i<s.length;i++)
	      g2.drawString(s[i],50,50+25*i);
    }
}

