...

/

Example 91: Cricket Scores

Example 91: Cricket Scores

Learn how to print cricketer details sorted in an ascending order based on their scores.

We'll cover the following...

Problem

A record contains the name of a cricketer, the age, the number of test matches he has played, and the average runs he scored in each test match. Create an array of structures to hold records of 5 such cricketers, and then write a program to read these records and arrange them in ascending order by average runs. Use the qsort() standard library function.

Try it yourself

Try to solve this question on your ...