1.

Write a c program to print the salary of employees by using switch case

Answer»

#include int MAIN() { CHAR id[10]; int hour; double value, salary; printf("Input the Employees ID(MAX. 10 chars): "); scanf("%s", &id); printf("\nInput the working hrs: "); scanf("%d", &hour); printf("\nSalary amount/hr: "); scanf("%lf", &value); salary = value * hour; printf("\nEmployees ID = %s\nSalary = U$ %.2lf\n", id,salary); return 0;}



Discussion

No Comment Found