#include<stdio.h>
main()
{
printf("==============================\n");
printf("=PROGRAM hitung harga diskon=\n");
printf("==============================\n");
float a,b,f;
char x[100];
printf("masukan nama barang=");
scanf("%s",&x);;
printf("masukan harga barang=");
scanf("%f",&a);
printf("persen diskon");
scanf("%f",&b);
f=a-(a*b/100);
printf("harga setelah diskon =%4.2f",f);
}
Tidak ada komentar:
Posting Komentar