Seeking programming C++ singer

All raw data can be output and displayed.

You can output the sorted scores of all singers.

Sorting requires a "quick sort" or "heap sort" method.

Can output display (first prize1; 3 second prizes; Fifth prize. ) Award-winning singer information.

# include & ltiostream.h & gt

const int LEN=30,M= 100,N = 100;

Typedef structure

{

Int num// lottery number

char name[LEN]; //Name

Floating score; //score

} players;

Player player [m]; //singer information

int a[M][N]; //Judges' scoring information

int m,n; //Number of singers and judges

//Enter the singer information and the judges' scoring information.

Invalid input (invalid)

{

int i,j;

Cout & lt& lt "number of singers":

CIN & gt; & gtm;

Cout & lt& lt "Number of judges:";

CIN & gt; & gtn;

for(I = 0; I & ltm;; i++)

{

Player [me]. num = I+ 1;

Cout & lt& lt "first"

CIN & gt; & gt player [me]. Name;

Cout & lt& lt "first"

for(j = 0; j & ltn; j++)

{

CIN & gt; & gta[I][j];

}

}

}

//Average (remove a highest score, remove a lowest score, and find the average of the remaining n-2 points.

Invalid calculation (invalid)

{

int max,min,I,j;

for(I = 0; I & ltm;; i++)

{

max=min=players[i]。 Score = a [I] [0];

for(j = 1; j & ltn; j++)

{

Player [me]. score+= a[I][j];

if(max & lt; a[i][j])

{

max = a[I][j];

}

if(min & gt; a[i][j])

{

min = a[I][j];

}

}

If (n>2)

{

Player [me]. Score = (player [me]. score-max-min)/(n-2);

}

else if(n & gt; 0)

{

Player [me]. score/= n;

}

}

}

//Rank the scores of each player by bubble method.

//If quick sorting or heap sorting is used, rewrite this paragraph.

Empty sort (void)

{

int i,j;

for(I = 0; I<m-1; i++)

{

for(j = m- 1; J> me; j -)

{

If (player [j]. Score & gt player [j- 1]. Score)

{

Player tmp

tmp = players[j];

Player [j]= player [j-1];

Player [j-1] = tmp;

}

}

}

}

//Display all raw data

Void display _ origin (void)

{

int i,j;

cout & lt& ltendl

for(I = 0; I & ltm;; i++)

{

Cout & lt& lt "Lottery number:"

Cout & lt& lt "Name:"

Cout & lt& lt "Judge's score:";

for(j = 0; j & ltn; j++)

{

cout & lt& lta[I][j]& lt; & lt" ";

}

cout & lt& ltendl

}

}

//Display the information of all singers.

Void show_player (invalid)

{

int I;

cout & lt& ltendl

for(I = 0; I & ltm;; i++)

{

Cout & lt& lt "Lottery number:"

Cout & lt& lt "Name:"

Cout & lt& lt "score:"

}

}

//Displays the information of the award-winning singer.

Invalid display _ medal (invalid)

{

int I;

cout & lt& ltendl

Cout & lt& lt "first prize 1:"

for(I = 0; I< 1. & amp & ltm;; i++)

{

Cout & lt& lt "Lottery number:"

Cout & lt& lt "Name:"

Cout & lt& lt "score:"

}

Cout & lt& lt "third prize:" < & ltendl "

for(; I< 1+3. & amp & ltm;; i++)

{

Cout & lt& lt "Lottery number:"

Cout & lt& lt "Name:"

Cout & lt& lt "score:"

}

Cout & lt& lt "Five third prizes:"

for(; I< 1+3+5. & amp & ltm;; i++)

{

Cout & lt& lt "Lottery number:"

Cout & lt& lt "Name:"

Cout & lt& lt "score:"

}

}

int main()

{

input();

show _ origin();

Calculate ();

show _ player();

sort();

show _ medal();

Returns 0;

}