Calcula média, usa JOptionPane e Usa Try/Finally.