PROGRAM TO CALCULATE BONUS

C, C++, etc Programing examples. Post as many you can. Test the programs and discuss about the output of the programes.
Forum rules
Please Discuss & post only about the programes and its Output

PROGRAM TO CALCULATE BONUS

Postby charulatha » Tue Apr 13, 2010 2:27 pm

/* PROGRAM ON BONUS */

#include<stdio.h>
#include<conio.h>

main()
{
int cur_yr,join_yr,ser_yr,bonus;
printf("Enter the current year and the year of joining\n");
scanf("%d%d",& cur_yr,&join_yr);
ser_yr=cur_yr-join_yr;
if(ser_yr>3)
{bonus=2500;
printf("Bonus=Rs.%d\n",bonus);}
else
exit(0);
getch();
}
Regards,
Charulatha.
User avatar
charulatha
Moderator
 
Posts: 756
Joined: Sat Oct 17, 2009 2:54 pm
membership: Senior Technician of The Institution of Engineers (India)- ST

ad
 

Return to Computer Notes : Some Sample Programs

Who is online

Users browsing this forum: No registered users and 0 guests