6. Binary Search [Problem description] Given the grade list of students in a class and your grade, find your position of Ken in the list according to his grade by the binary search method. The grade list is an ordered list and sorted ascendingly. The maximal length of the grade list is 100. [Basic requirements] Use the binary search method. [Example] What you need to show in the terminal (the back part is outputted by you and the blue part is inputted by the user, i. e., teacher) : Please input the student grade list: Alice:73 Bob: 80 Mark:82 David:84 Jenny: 89 Maria:93 Please input the grade of Ken: 06 The position of Ken is:

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter17: Linked Lists
Section: Chapter Questions
Problem 8PE
icon
Related questions
Question
100%

IN C++ please follow the example interface

6. Binary Search
[Problem description]
Given the grade list of students in a class and your grade, find your position
of Ken in the list according to his grade by the binary search method. The
grade list is an ordered list and sorted ascendingly. The maximal length of
the grade list is 100.
[Basic requirements]
Use the binary search method.
[Example]
What you need to show in the terminal (the back part is outputted by you and
the blue part is inputted by the user, i. e., teacher) :
Please input the student grade list:
Alice:73
Bob: 80
Mark:82
David:84
Jenny: 89
Maria:93
Please input the grade of Ken:
06
The position of Ken is:
Transcribed Image Text:6. Binary Search [Problem description] Given the grade list of students in a class and your grade, find your position of Ken in the list according to his grade by the binary search method. The grade list is an ordered list and sorted ascendingly. The maximal length of the grade list is 100. [Basic requirements] Use the binary search method. [Example] What you need to show in the terminal (the back part is outputted by you and the blue part is inputted by the user, i. e., teacher) : Please input the student grade list: Alice:73 Bob: 80 Mark:82 David:84 Jenny: 89 Maria:93 Please input the grade of Ken: 06 The position of Ken is:
Expert Solution
steps

Step by step

Solved in 2 steps with 2 images

Blurred answer
Knowledge Booster
Functions
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr