Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C++ Please code using C++ Write a program to fill a vector with 5000 random numbers. Then display: . The smallest number The largest number

C++ Please code using C++ image text in transcribed
image text in transcribed
Write a program to fill a vector with 5000 random numbers. Then display: . The smallest number The largest number . The number of odd values . The number of even values . The total of the values . The average of the values . Ask the user for an integer and display the subscript of the cell where it was found or NOT FOUND! if it isn't found. You will be using a binary search to locate the index of the integer requested by the user. Since you will be using a binary search, the vector will have to be in order. Under "Materials" in this week's module, there is a file that contains two functions that you will need to include in your code to sort your vector shellSort() and swapper). You can download the file, "Activity 25 Sort Functions.cpp," directly, of click the following link for a .zip file that contain:s t: Download and unzip the shellSort and swapper function Each of the preceding values should be determined by a function and returned to main where thev

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Informix Database Administrators Survival Guide

Authors: Joe Lumbley

1st Edition

0131243144, 978-0131243149

More Books

Students also viewed these Databases questions

Question

a. Given the circumstances, what decision should the CEO make? Why?

Answered: 1 week ago

Question

LO1 Understand risk management and identify its components.

Answered: 1 week ago