Friday, March 1, 2013

program C mencari nilai

#include<stdio.h>

int main()
{
int b;

printf("masukkan nilai= ");
scanf("%d",&b);

if(b => 80 && b <100)
printf("nilai A");
else if(b>70)
printf("nilai B");
else if(b>60)
printf("nilai C");
else if(b>40)
printf("nilai D");
else if(b >20 && b >0)
printf(" nialai E");

return 0;

}


0 comments :

Post a Comment