import javax.swing.*;
class ALLERT{
public static void main (String []args) {
try { //Andi Mahyudin
String NPM = JOptionPane.showInputDialog("Masukkan NPM");
int Npm = Integer.parseInt(NPM);
String nama = JOptionPane.showInputDialog ("Masukkan Nama");
String Jurusan = JOptionPane.showInputDialog ("Jurusan");
String Fakultas = JOptionPane.showInputDialog ("Fakultas");
String semester = JOptionPane.showInputDialog ("Semester ke-");
int Semester = Integer.parseInt(semester);
String kelamin = JOptionPane.showInputDialog ("Jenis Kelamin");
String tlp = JOptionPane.showInputDialog ("No. Telp");
String Tlp = Integer.parseInt(tlp);
String Email = JOptionPane.showInputDialog ("Email");
JOptionPane.showMessageDialog (null,"NPM : "+NPM+"\nNama : "+nama+
"\nJurusan : "+Jurusan+"\nFakultas : "+Fakultas+"\nSemester : "+semester+"\nJenis Kelamin : "+kelamin+"\nNo. Telp : "+tlp,
"MASTER DATA MAHASISWA",JOptionPane.ERROR_MESSAGE);
}
catch (Exception e) {
JOptionPane.showMessageDialog(null,"Data tidak valid, Masukkan data yang benar","ERROR",JOptionPane.WARNING_MESSAGE);
}
}
}