import java.awt.Container;
import javax.swing.*;

public class H6_Dia25 extends JApplet
{
	public void init()
	{
		double getal1 = Double.parseDouble(JOptionPane.showInputDialog("Geef het eerste getal: "));
		double getal2 = Double.parseDouble(JOptionPane.showInputDialog("Geef het eerste getal: "));
		double getal3 = Double.parseDouble(JOptionPane.showInputDialog("Geef het eerste getal: "));
		
		double max = maximum(getal1, getal2, getal3);
		
		JTextArea outputArea = new JTextArea();
		
		outputArea.setText("Getal 1: " + getal1 + "\nGetal 2: " + getal2 + "\nGetal 3: " + getal3 + "\n\nHet maximum is: " + max);
		
		Container container = getContentPane();
		
		container.add(outputArea);
	}
	
	public double maximum (double x, double y, double z)
	{
		return  Math.max(x, Math.max(y, z));
	}
}