subject

C++ Write a program that initially asks a user to enter two positive integer numbers a and b. If either a or are zero or negative, the program terminates right away. Then, generate an array of 20 integer numbers, each randomly generated between a and b. If b happens to be greater than a, then the array must contain elements randomly generated between b and a. Display the whole array on the screen. After creating and displaying the array, the program shows: [A]verage [S]um [F]ind Please choose an option: Then, if the user selects:
- A (lowercase or uppercase): the program computes and displays the average of all elements of the array
-A (lowercase or uppercase): the program computes and displays the average of all elements of the array
-F (lowercase or uppercase): the program asks the user to insert an integer number to be found in the array
If present, the program displays "Found in position number followed by the position of the first occurrence.
If not present, the program displays "Number not found in the array"

ansver
Answers: 1

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 10:40, almaga1979orfvwo
5. illustrate how fine-line inventory classification can be used with product and market segments. what are the benefits and considerations when classifying inventory by product, market, and product/market?
Answers: 2
image
Computers and Technology, 22.06.2019 22:30, Metlife
You are new to microsoft certification and want to start out by getting a certification geared around windows 8. what microsoft certification should you pursue?
Answers: 1
image
Computers and Technology, 24.06.2019 10:00, lashaunahard
Each time you save a document, you will need to type in the file type in which it should be saved you can select the save button to save it with the same file name if it has been previously saved you will need to select the location to save the file you will need to use the save as dialog box
Answers: 1
image
Computers and Technology, 24.06.2019 18:30, trevorhenyan51
Dereck works for long hours on his computer.  he frequently experiences physical strain by the end of the day because he does not follow an important rule of ergonomics with respect to the use of keyboards.  which of the following actions of dereck could lead to physical strain? a.  placing the keyboard exactly in front of him while typingb.  keeping hands and wrists straight while typingc.  using wrist pads throughout the dayd.  pounding at the keys on the keyboard while typinge.  resting his hands on the keyboard when he is not typing
Answers: 1
You know the right answer?
C++ Write a program that initially asks a user to enter two positive integer numbers a and b. If eit...

Questions in other subjects:

Konu
Mathematics, 04.06.2020 02:58
Konu
Mathematics, 04.06.2020 02:58
Konu
Biology, 04.06.2020 02:58
Konu
Business, 04.06.2020 02:58