/*program to calculate hra,da in salary if salary less than
10000 then hra15%,da13% otherwise hra20%,da18%/*
Answer Posted / rama krishna sidhartha
#include<stdio.h>
#include<conio.h>
void main()
{
long int bs,da,hra;
clrscr();
printf("\n enter the basic salary of employee=");
scanf("%f",&bs);
if (bs<10000)
{
printf("\n da : %f",da=(bs*15)/100);
printf("\n hra : %f",hra=(bs*13)/100);
printf("\n net salary: %f",da+hra);
}
else
{
printf("\n da : %f",da=(bs*20)/100);
printf("\n hra : %f",hra=(bs*18)/100);
printf("\n net salary: %f",da+hra);
}
getch();
}
| Is This Answer Correct ? | 11 Yes | 0 No |
Post New Answer View All Answers
How can I change their mode to binary?
Explain how are portions of a program disabled in demo versions?
What is 2c dna?
Is c high or low level?
What are pointers? Why are they used?
Where register variables are stored in c?
Which operators cannot be overloaded a) Sizeof b) .* c) :: d) all of the above
WHAT IS THE DEFINATION OF IN TECHNOLOGY AND OFF TECHNOLOGY ?
What is the use of static variable in c?
What is difference between array and structure in c?
What is fflush() function?
Can you please explain the difference between exit() and _exit() function?
What are preprocessor directives in c?
Q.1 write aprogram to stack using linklist o insert 40 items? Q.2 write a program to implement circular queue with help of linklist?
Should a function contain a return statement if it does not return a value?