1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Firlakuza [10]
3 years ago
5

Write a C++ program that declares an array alpha of 50 components of type double. Initialize the array so that the first 25 comp

onents 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.
Computers and Technology
1 answer:
pshichka [43]3 years ago
7 0

Answer:

#include <iostream>

#include <array>

static std::array<double, 51> nums;

int main()

{

std::array<double, 51> nums;

int for1;

int for2;

for (int i = 0; i < 26; i++)

{

             nums[i] = i;

             for1 = i * i;

             std::cout << for1 << ", ";

             if(i%10==0)

                 std::cout << "\n";

}

for (int i = 26; i < 51; i++)

{

             nums[i] = i;

             for2 = i * 3;

             std::cout << for2 << ", ";

             if (i % 10 == 0)

                 std::cout << "\n";

}

}

hope i helped :D

You might be interested in
Will give Brainiest and stuff to right answer[s].
Aneli [31]
#22 is 1s and 0s, hope that helps a little bit
6 0
3 years ago
Read 2 more answers
To inspire unit 1 App
Tasya [4]
Is there more to this or ?
5 0
3 years ago
AirPods se están despintando al ponerlos en quitaesmalte ayudaaaa?
slega [8]

Answer:

In reality, a diluted type of acetone that dissolves plastics and coating is Nail polish removers.

Explanation:

The chemical composition of the material has permanently changed, nothing else than if you had shot it. No repair but replacement is available.

Acetone does not get along with plastics.

This classic timelapse video shows just how cheap plastic acetone is.

When it's out, I have my new AirPods Pro. I got a odd smell when I opened the box when I received it. The little one is solid and chemical. It's new, I guess, and after days it will be gone.

But after ten days of use it doesn't. And the smell remains strong. It won't go quickly, I believe.

Instead I noticed that the smell is often shaping the silicone tips.

About 8 hours a day I use this AirPods Pro. Is it possible for a long time to use this smelling tip?

Actually, I must say they are soft and work well for noise cancelation, I love this silicone tip. If the strange smell doesn't hurt. To me, that's good.

6 0
3 years ago
Write a MIPS assembly language program that prompts for a user to enter a series of floating point numbers and calls read_float
LenaWriter [7]

Explanation:

Here if the value in the register $f2 is equals to the value in $f4, it jumps to the Label1. If it should jump when the value in the register $f2 is NOT equals to the value in $f4, then it should be

4 0
3 years ago
The ____________ command / function is used in Python graphics and text-based programming code.
sleet_krkn [62]

A. write()

2.4. Graphics

Graphics make programming more fun for many people. To fully introduce

graphics would involve many ideas that would be a distraction now. This section

4 0
2 years ago
Other questions:
  • You are given a string of n characters s[1 : : : n], which you believe to be a corrupted text document in which all punctuation
    12·1 answer
  • ___ is the branch of computer science that explores techniques for incorporating aspects of intelligence into computer systems.
    5·1 answer
  • Which group on the sparkline tools design tab would you choose if you wanted to change the data source of the sparkline? (1 poin
    10·1 answer
  • I need help!!!!
    13·2 answers
  • Multiple client switches and routers have been set up at a small military base. The network team decided to implement Terminal A
    15·1 answer
  • We made a distinction between the forwarding function and the routing function performed in the network layer. What are the key
    6·1 answer
  • What is file management?can please help me​
    14·2 answers
  • CALLING ALL DEKUS UWU
    15·2 answers
  • A software is made from​
    10·1 answer
  • In the following shell scripting extract, the initial values of variables s, c and p are 0, 1, 1 respectively. What will be the
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!