Trainers at Tom’s Athletic Club are encouraged to enroll new members. Write an application that allows Tom to enter the names of each of his 25 trainers and the number of new members each trainer has enrolled this year. Output is the number of trainers who have enrolled 0 to 5 members, 6 to 12 members, 13 to 20 members, and more than 20 members.

Respuesta :

Answer:

The applicatiion and its program output are given below

Explanation:

start

    declaration:

  int numberOfMember,totalNumber,j=0

string array05[totalNumber],array612[totalNumber],array1320[totalNumber],arrayMore20[totalNumber]

string trainerName;

Loop start:

           for i=0-totalNumber

                    totalNumber=number of trainers

                    trainerName=name of trainer

                   numberOfMember=number of memberas added

                    if numberOfMember=0-5

                                  array05[j]=trainerName;

                       elseif numberOfMember=6-12

                                      array612[j]=trainerName;

                       elseif numberOfMember=13-20

                                      array1320[j]=trainerName;

                        else

                                 arrayMore20[j]=trainerName;      

                   j+=1;

end loop

Output:

for i=0-j

print    array05[i]    array612[i]    array1320[i]      arrayMore20[i]

End