#include <iostream.h>
#include <conio.h>
void main()
{
char emp_nm[10], mon_sal[10];
/* ....Input .... */
for(int i = 0; i< 10; i++)
{
cout<<"\n enter the name of an employee :";
cin >> emp_nm[i];
cout<<"\n Enter the salary :";
cin>>mon_sal[i];
}
cout<< "Name" << "\t\t" << "Salary" << endl;
for(i = 0; i< 10; i++)
{
// Check annual salary ....
if(mon_sal[i]*12 >= 250000)
cout<< emp_nm[i] << "\t\t"<< mon_sal[i] << "tax-to-be-paid"<< "\n" ;
else
cout<< emp_nm[i] << "\t\t"<< mon_sal[i] << "no-tax"<< "\n" ;
}
getch();
}
No comments:
Post a Comment