Im new in eclipse and i don't know how is it. to make my simple console application exported to .exe file, or anything to make my console app can be executable, without I open the eclipse IDE
this my only class i have, anyone can help me?
import java.util.Scanner;
public class MainClass {
public static void main(String[] args) {
// TODO Auto-generated method stub
Scanner key = new Scanner(System.in);
System.out.println("### Selamat Datang di money Changer ###");
System.out.print("Masukan Mata uang anda: ");
String matauang = key.nextLine();
System.out.print("Anda memasukan "+matauang.toUpperCase());
System.out.print(" Masukan Nominal uang anda: ");
String nilaI = key.nextLine();
Integer hasilnya = money(matauang,Integer.parseInt(nilaI));
System.out.print(" Rupiah yang anda tukar menjadi "+hasilnya+" "+matauang);
}
static Integer money(String matauang, Integer jml) {
Integer hasil = 0;
if(matauang.equals("Dolar")) {
hasil = jml/11000;
}else if (matauang.equals("Ringgit")) {
hasil = jml/7000;
}
return hasil;
}
}