12,449,910 members (46,798 online)
See more:
```# include <iostream>
using namespace std;

void Salary (int S[],int Size){

for (int i=0;i<=4;i++)
cout<<" Enter The Salary for Five Employee";
cin>>S[i];

}

int MaxS (int S[],int Size){

int max=0;

for (int i=0;i<=4;i++){
if (max<S[i])
max=S[i];
return max;

}

int Index (int S[],int Size){
int x;
cout<<" Enter The Salary of the Employee";
cin>>x;
for(int i=0;i<=4;i++){
if (x==S[i])
return i;
}
}

void Sort (int S[],int Size){
int temp;
for ( int i=0; i<=3;i++){
for ( int j=0;j<=3;j++){
if (S[j]>S[j+1]){
temp=S[j];
S[j]=S[j+1];
S[j+1]=temp;
}
}
}
for ( int m=0;i<=4;i++){
cout<<S[m];
}
}

void Dis (int S[],int Size){

cout<<" Employee Number \t\t"<<" Salary \n";
for (int i=0;i<=4i++){
cout<<i<<"\t\t"<<S[i];
}

int sum=0;
for (int i=0;i<=4;i++){
sum+=S[i];
}
return sum;
}
int sum=0;
for(int i=2;i<=4;i++){
sum+=S[i];
return sum;
}

void main(){
int Size = 5,ch;

Salary (S,5);
do{
cout<<" Find The Max of Salaries";
cout<<" Find The Position of The Employee";
cout<<" Sort The Salary";
cout<<" Display The Salary In the Table Form";
cout<<" Adds The Third, Forth and Fifth Salary;

switch (ch){
case 1:
cout<<"The Max of The Salary"<<Maxs(S,5);
break;
case 2:
cout<<"The Index of Empoyee"<<Index(S,5);
break;
case 3:
Sort(S,5);
break;
case 4:
Dis(S,5);
break;
case 5:
cout<<" The Adds of The Salaries is"<<sum;
break;
case 6:
cout<<" The Adds of The Third, Fourth and Fifth Salary is";
break;
defualt:
cout<<" wrong Choice ";
break;
}

}while (ch<=4)
}```
Closed because this post is not a question, or has not been phrased in a way that allows a reasonable answer to be provided. Reported by Chris Maunder, __TR__ on Sunday, December 30, 2012 3:40pm
Posted 30-Dec-12 0:38am
Closed 30-Dec-12 0:44am
v2

Top Experts
Last 24hrsThis month
 OriginalGriff 305 Maciej Los 133 Karthik Bangalore 130 David_Wimbley 110 ppolymorphe 104
 OriginalGriff 5,988 Karthik Bangalore 3,465 ppolymorphe 3,426 Maciej Los 3,005 Richard Deeming 2,805