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
kramer
3 years ago
13

Int[] numList = {2,3,4,5,6,7,9,11,12,13,14,15,16}; int count=0; for(int spot=0; spot

Physics
1 answer:
pickupchik [31]3 years ago
4 0

Hi, there is not much information about what do you need to do, but base on the C++ code you need to complete it to count the number of items in the array, using the instructions already written.

Answer:

#include <iostream>

using namespace std;

int main()

{

   int numList [] = {2,3,4,5,6,7,9,11,12,13,14,15,16};

   int count=0;

   for(int spot=0; spot < (sizeof(numList)/sizeof( numList[ 0 ])); ++spot)

   {

        cout << numList[spot];

        cout << "\n";

        ++count;

   }

   cout << "The number of items in the array is: ";

   cout << count;

   return 0;

}

Explanation:

To complete the program we need to finish the for statement, we want to know the number of items, we can get it by using this expression:  (sizeof(numList)/sizeof( numList[ 0 ])), sizeof() function returns the number of bytes occupied by an  array, therefore, the division between the number of bytes occupied for all the array (sizeof(numList)) by the number of bytes occupied for one item of the array (sizeof( numList[ 0])) equal the length of the array. While iterating for the array we are increasing the variable count that at the end contains the result that we print using the expression cout << "The number of items in the array is: "

You might be interested in
The Jamaican bobsled team was moving at a velocity of 50 m/s, then they hit the brakes on their sled to decelerate at a uniform
atroni [7]

Answer:

The time it took the bobsled to come to rest is 10 s.

Explanation:

Given;

initial velocity of the bobsled, u = 50 m/s

deceleration of the bobsled, a = - 5 m/s²

distance traveled, s = 250 m

Apply the following kinematic equation to determine the time of motion of the bobsled;

s = ut + ¹/₂at²

250 = 50t + ¹/₂(-5)t²

250 = 50t - ⁵/₂t²

500 = 100t - 5t²

100 = 20t -t²

t² - 20t + 100 = 0

t² -10t - 10t + 100 = 0

t (t - 10) - 10(t - 10) = 0

(t - 10)(t - 10) = 0

t = 10 s

Therefore, the time it took the bobsled to come to rest is 10 s.

3 0
3 years ago
Nutritionists use the ______ to measure how much energy we get from foods.
Natali [406]
<span>It is measured in calories </span>
6 0
4 years ago
Read 2 more answers
If it has enough kinetic energy, a molecule at the surface of the Earth can "escape the Earth's gravitation", in the sense that
user100 [1]

Answer:

K_E=mgr_E

Explanation:

By conservation of energy, the sum of the kinetic and gravitational potential energies at the surface of the Earth must be equal than their sum at infinity, so we have:

K_E+U_E=K_\infty+U_\infty

\frac{mv_E^2}{2}-\frac{GM_Em}{r_E}=\frac{mv_\infty^2}{2}-\frac{GM_Em}{r_\infty}

Where G=6.67\times10^{-11}Nm^2/kg^2 is the gravitational constant,M_E=5.97\times10^{24}kg and r_E=6371000m are the mass and radius of the Earth, <em>m </em>is the mass of the particle, v_E its velocity at the surface of the Earth (which would be its escape velocity) and v_\infty and r_\infty are the velocities and distance at infinity, which would be null and infinity respectively, so the right hand side of our equation is 0J, which leaves us with:

\frac{GM_Em}{r_E}=\frac{mv_E^2}{2}=K_E

Also, since the force the molecule experiments is the force of gravity (disregarding drag), we can write its weight in terms of Newton's Law of Gravitation:

F=mg=\frac{GM_Em}{r_E^2}

Which means that:

\frac{GM_Em}{r_E}=mgr_E

So finally putting all together we can write:

K_E=\frac{GM_Em}{r_E}=mgr_E

4 0
3 years ago
At what point should a business information manager assume that he or she will not receive any more new questions or requests to
stealth61 [152]

There are always new questions to answer and new problems to solve in this area. The correct option is D.

<h3>Why is problem solving essential in business?</h3>

It is a necessary skill for supervisors and other senior positions. Individuals who have excellent problem-solving skills are a precious and considered reliable attribute in any team.

They are the ones who come up with new ideas, better ways of operating, make things easier to understand, or help customers save time and money.

Before attempting to solve a problem, ascertain whether it is truly a problem. In addition to you, but additionally to those who are affected.

In this line of work, there are always fresh questions to answer and problems to solve.

Thus, the correct option is D.

For more details regarding problem solving, visit:

brainly.com/question/3418829

#SPJ1

7 0
2 years ago
You run to your girlfriend's house and announce that you were running at a rate of 15 miles per hour. She knows this is not true
Sunny_sXe [5.5K]

Answer:how long it took you to get there and the distance between your house and her house

Explanation:

8 0
3 years ago
Other questions:
  • During a breath, the average human lung expands by about 0.50 l. part a if this expansion occurs against an external pressure of
    15·1 answer
  • A hockey player uses a leaf blower to apply a constant force on a hockey puck. The puck accelerates in a straight line across th
    5·1 answer
  • What was the main view how the world worked geologically prior to the 1960s? It was generally believed that continents and ocean
    9·1 answer
  • What does electrons and the nucleus have in common?
    9·1 answer
  • Review the work-energy theorem and apply it to a simple problem.
    14·1 answer
  • A 92-kg skier is sliding down a ski slope that makes an angle of 30 degrees above the horizontal direction. The coefficient of k
    6·1 answer
  • Suppose that the resistance between the walls of a biological cell is 4.2 × 109 Ω. (a) What is the current when the potential di
    5·1 answer
  • An insulated beaker with negligible mass contains liquid water with a mass of 0.285 kg and a temperature of 75.2 ∘C How much ice
    7·1 answer
  • A one-piece cylinder has a core section protruding from the larger drum and is free to rotate around its central axis. A rope wr
    11·1 answer
  • Characteristics of highly sensitive galvonometer​
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!