Question: uestion 1 - store this program in a file named Q 1 . cpp Write a program that asks the user to enter an integer

uestion 1- store this program in a file named Q1.cpp
Write a program that asks the user to enter an integer number (let's name this integer number target). Then, the program will ask the user to enter 15 integer numbers that will be stored in an array of integers (Let's call this array intArray).
Your program uses the Insertion sort algorithm to sort the array in descending order (maximum first, minimum last).
Your program uses the Binary search algorithm to determine if the target is equal to any element in the intArray. This binary search algorithm should work in an array that is sorted in descending order.
Your program must display the index of the element in sorted intArray which is equal to the target.
If the target can't be found, your program displays an appropriate message.
uestion 1 - store this program in a file named Q

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!