Contoh Aplikasi Gaji Perusahaan Penerbangan dengan Bahasa C++

Mau share aja nih contoh aplikasi C++

#include
#include
#include
//Nama : M Randy Mandala Putra //

main()
{
int n, i, totalbonus=0, bonus, notim, rute, subtotal, bonuspil, bonusko, bonuspram;
char pilot1[]="Joan Sakti Mandraguna";
char pilot2[]="Gatot Mangkulangit";
char pilot3[]="Wakarsyah Amanah M";
char kopilot1[]="Sungkar Belana";
char kopilot2[]="Alex Ananda Lobahutang";
char kopilot3[]="Bremamana Sakyah Marta";
char pram1[]="Indah, Diah, Agnes";
char pram2[]="Cantik, Cinta, Citra";
char pram3[]="Windi, Wita, Wina";
char p[]="Pilot";
char k[]="Kopilot";
char pr[]="Pramugari";
char nama;

//Input//
printf("Masukan banyaknya data yang akan diproses : t");
scanf("%d", &n);

printf("-----------------------------PT. RAJAWALI SAKTI---------------------------------n");
printf("-------------------------Oleh : M Randy Mandala Putra---------------------------n");
for(i=1;i{
printf("================================================================================n");
printf("NOMOR TIM : t"); scanf("%d", &notim); //input tim//
printf("NOMOR RUTE : t"); scanf("%d", &rute);
printf("================================================================================n");
printf("NAMA JABATAN BONUS:n");
printf("================================================================================n");
if(rute==1)
{ bonuspil=100000, bonusko=85000, bonuspram=(50000*3); }
else
if(rute==2)
{ bonuspil=90000, bonusko=80000, bonuspram=(45000*3); }
else
if (rute==3)
{ bonuspil=60000, bonusko=50000, bonuspram=(30000*3);}

if(notim==1)
{
printf("n %10s %10s %10d n %10s %10s %10d n %10s %10s %10d n ", pilot1, p,bonuspil, kopilot1, k,bonusko, pram1, pr,bonuspram); }
if(notim==2)
{
printf("n %10s %10s %10d n %10s %10s %10d n %10s %10s %10d n ", pilot2, p,bonuspil, kopilot2, k,bonusko, pram2, pr,bonuspram); }
if(notim==3)
{
printf("n %10s %10s %10d n %10s %10s %10d n %10s %10s %10d n ", pilot3, p,bonuspil, kopilot3, k,bonusko, pram3, pr,bonuspram); }
subtotal=bonuspil+bonusko+bonuspram;
printf(" ________________________n");
printf(" SUBTOTAL : Rp.%10d n",subtotal);
totalbonus+=subtotal;}
printf("_______________________________________________________________________________n");
printf("TOTAL BONUS :Rp.%10d", totalbonus);
getch();
}

1 thought on “Contoh Aplikasi Gaji Perusahaan Penerbangan dengan Bahasa C++”

Leave a Comment