import javax.swing.JOptionPane;
public class Area {
public static void main(String[] args) {
String b = JOptionPane.showInputDialog(null,"informe a base: ");
float base = Float.parseFloat(b);
String a = JOptionPane.showInputDialog(null, "informe a altura: ");
float altura = Float.parseFloat(a);
float area = (base * altura) / 2;
JOptionPane.showMessageDialog(null, area);
}
}