//efek salju

Kamis, 08 November 2012

perhitungan kasir menggunakan c++


#include 
#include
 
void main()
{
int BYKB,JLHU;
float HS,JML,kemb;
printf("+-----------------------------+\n");
printf("| RAYHAN |\n");
printf("| contoh program kasir |\n");
printf("+-----------------------------+\n\n");
printf("Masukkan Jumlah Barang = ");
scanf("%d",&BYKB);
printf("Masukkan Harga Barang = ");
scanf("%f",&HS);
JML=BYKB*HS ;
printf(" Total Bayar Anda =%f ",JML);
printf("\n============================");
printf("\n Jumlah Uang = "); scanf("%d",&JLHU);
kemb= JLHU-JML;
printf("Kembalian Anda = %f",kemb);
}