import java.io.* ;
class lat6{
public static void main(String Arg[]) throws IOException{
String str ;
String NIP ;
String Nama ;
String jbt ;
double gaji=0 ;
double pajak =0 ;
double total=0 ;
int pil, Kdj ;
BufferedReader Get=new BufferedReader(new InputStreamReader(System.in)) ;
do{
System.out.println("Menu utama");
System.out.println("1. Mengitung gaji pegawai");
System.out.println("2. Anda mau keluar, Huff");
System.out.print("Pilihan anda Coy !!! : "); str = Get.readLine() ;
pil= Integer.parseInt(str) ;
switch(pil){
case 1:
System.out.print("NIP : ") ; NIP = Get.readLine() ;
System.out.print("Nama : ") ; Nama = Get.readLine() ;
System.out.print("Kode : ") ; str = Get.readLine() ;
Kdj = Integer.parseInt(str) ;
if (Kdj==1) {
jbt = "Direktur" ; gaji = 5000000 ;
} else if (Kdj==2) {
jbt = "Wakil Direktur" ; gaji = 4000000 ;
} else if (Kdj==3) {
jbt = "Bendahara" ; gaji = 3000000 ;
} else if (Kdj==4) {
jbt = "Staf" ; gaji = 2000000 ;
} else {
jbt = "" ; gaji = 0 ;
}
pajak = 0.1 * gaji ;
total = gaji-pajak ;
System.out.println("Jabatan : " + jbt ) ;
System.out.println("Gaji : " + gaji) ;
System.out.println("Pajak : " + pajak ) ;
System.out.println("Total : " + total ) ;
break ;
}
System.out.print("Created By Azlan"); str = Get.readLine() ;
}while(pil != 2);
}
}
Tags :
Tugas pak Mes !!!!!!!! | BELAJAR BERSAMA | PANIPAHAN: Tugas pak Mes !!!!!!!!
Langganan:
Posting Komentar (Atom)
0 komentar:
Posting Komentar