subject
Computers and Technology, 08.11.2020 05:30 iva60

Write a C++ program that declares an array alpha of 50 components of type double. Initialize the array so that the first 25 components are equal to the square of the index variable (the position that element will occupy), and the last 25 components are equal to three times the index variable. Output the array so that 10 elements per line are printed. For the number at index 5, the value would be 25, which is 5 squared. The 25th index would hold a value of 75, which is 3 * 25.

An example of the program output is shown below:

0 1 4 9 16 25 36 49 64 81
100 121 144 169 196 225 256 289 324 361
400 441 484 529 576 75 78 81 84 87
90 93 96 99 102 105 108 111 114 117
120 123 126 129 132 135

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 04:30
Which of the statements below is true? the formatting, standard, and drawing commands are unavailable. the formatting, standard, and drawing commands have been used. the formatting, standard, and drawing toolbars are displayed. the formatting, standard, and drawing toolbars are hidden.
Answers: 1
question
Computers and Technology, 22.06.2019 11:00
What are two of the most common reasons that peolpe who need mental health care do not access it?
Answers: 1
question
Computers and Technology, 23.06.2019 21:40
language consists of basic components, and they are called a. 3; mental images, concepts, and speech b. 2; language acquisition and linguistic relativity c. 3; heuristics, algorithms, and analogies d. 4; phonemes, morphemes, syntax, and semantics e. 2; words and grammar
Answers: 3
question
Computers and Technology, 23.06.2019 23:30
Match the following errors with their definitions. a. #name b. #value c. #ref d. 1. when a formula produces output that is too lengthy to fit in the spreadsheet cell 2. when you enter an invalid cell reference in a formula 3. when you type text in cells that accept numeric data 4. when you type in a cell reference that doesn’t exist
Answers: 1
You know the right answer?
Write a C++ program that declares an array alpha of 50 components of type double. Initialize the arr...
Questions
question
Mathematics, 09.03.2021 22:20
question
English, 09.03.2021 22:20
question
Mathematics, 09.03.2021 22:20
Questions on the website: 13722362