Professor X. wants to assess the performance in her class. So, she wants to find what grades students have received and

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

Professor X. wants to assess the performance in her class. So, she wants to find what grades students have received and

Post by answerhappygod »

Professor X. wants to assess the performance in her class. So,she wants to find what grades students have received and for eachgrade, how many students have received that particular grade. Forexample, if the grades are [100, 99, 100, 96, 99, 99], then youhave to determine that there are 2 students having grade 100, 3having grade 99, and 1 having grade 96.
Write a pseudo-code to achieve this. Clearly state whatdata structure you use and what complexity youachieve.
Assume that your input is an array of length N containing allthe grades (not sorted), where N is the number of students in theclass
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply