P005.c (447B)
1 /* A person is paid Rs. 455 for each day he works and fined 2 Rs. 150 for each day he remains absent. WAP to calculate his 3 monthly income taking the number of days present as input. */ 4 5 #include<stdio.h> 6 int main() { 7 int daily_wage = 455, fine = 150, present, absent, income; 8 printf("No of days present : "); 9 scanf("%d", &present); 10 absent = 30 - present; 11 income = (present * 455) - (absent * 150); 12 printf("\nIncome : %d",income); 13 return 0; 14 }