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
Svetach [21]
3 years ago
6

You are given a partial implementation of one header file, GildedRose.hpp. Item is a class that holds the information for each i

tem in the store. GildedRose is a class that holds a listing of Item objects. This inventory should hold at least 10 items. For this you should use C containers. You should use a container from the ones you have studied so far such as the vector or the array. Complete the implementation of GildedRose class, adding public/private member variables and functions as needed. The implementation of Item class is already done for you. You should choose an appropriate data structure to maintain this inventory with an unknown size, known only at runtime. Your code is tested in the provided main.cpp. You will need to implement the following functions: Constructors/Destructors - Initialize your data. Allocate memory where necessary. The destructor should deallocate memory where necessary. size() - This should return the number of items currently for sale (this is different from the capacity). get(size_t) - This should return the item with the matching index. For example if given an index of 3, you should return the item at index 3 in the list. add(Item) - This should add another item for sale in the Gilded Rose by adding it to your inventory. operator[](size_t) - This should perform identical to the get(size_t) function. Initially the given code will not compile. As you complete the code, the tests should start to pass in main.cpp.

Engineering
1 answer:
devlian [24]3 years ago
3 0

Answer:

The answer is attached below

Explanation:

You might be interested in
What are the functions of a gear
iogann1982 [59]
It’s engineering gnzvxhfhbkchufkh
6 0
3 years ago
Read 2 more answers
What does Clay say will happen if the system is rejected?
juin [17]

Answer:

the nation will suffer terrible consequences

Explanation:

I did that and got it right

6 0
3 years ago
Read 2 more answers
Sea water with a density of 1025 kg/m3 flows steadily through a pump at 0.21 m3 /s. The pump inlet is 0.25 m in diameter. At the
myrzilka [38]

Answer:

\dot W_{pump} = 16264.922\,W\,(16.265\,kW)

Explanation:

The pump is modelled after applying Principle of Energy Conservation, whose form is:

\frac{P_{1}}{\rho\cdot g}+ \frac{v_{1}^{2}}{2\cdot g} +z_{1} + h_{pump}=\frac{P_{2}}{\rho\cdot g}+ \frac{v_{2}^{2}}{2\cdot g} +z_{2}

The head associated with the pump is cleared:

h_{pump} = \frac{P_{2}-P_{1}}{\rho\cdot g}+\frac{v_{2}^{2}-v_{1}^{2}}{2\cdot g}+(z_{2}-z_{1})

Inlet and outlet velocities are found:

v_{1} = \frac{0.21\,\frac{m^{3}}{s} }{\frac{\pi}{4}\cdot (0.25\,m)^{2} }

v_{1} \approx 4.278\,\frac{m}{s}

v_{2} = \frac{0.21\,\frac{m^{3}}{s} }{\frac{\pi}{4}\cdot (0.152\,m)^{2} }

v_{2} \approx 11.573\,\frac{m}{s}

Now, the head associated with the pump is finally computed:

h_{pump} = \frac{175\,kPa-81.326\,kPa}{(1025\,\frac{kg}{m^{3}} )\cdot (9.807\,\frac{m}{s^{2}} )} +\frac{(11.573\,\frac{m}{s} )^{2}-(4.278\,\frac{m}{s} )^{2}}{2\cdot (9.807\,\frac{m}{s^{2}} )} + 1.8\,m

h_{pump} = 7.705\,m

The power that pump adds to the fluid is:

\dot W_{pump} = \dot V \cdot \rho \cdot g \cdot h_{pump}

\dot W_{pump} = (0.21\,m^{3})\cdot (1025\,\frac{kg}{m^{3}})\cdot (9.807\,\frac{m}{s^{2}})\cdot(7.705\,m)

\dot W_{pump} = 16264.922\,W\,(16.265\,kW)

4 0
3 years ago
Saul is testing an installation and discovers a short circuit. What's causing this?
sergey [27]
A high voltage!! Hope this helps
6 0
3 years ago
Required information NOTE: This is a multi-part question. Once an answer is submitted, you will be unable to return to this part
ra1l [238]

Answer:

h1 = 290.16kj/kg

P = 1.2311

Prandil expression at 8

P=p1/p7×pr

=8(1.2311)

=9.85

Enthalpy state at 8 corresponding to 9.85

h1 = 526.13kj/kg

Now prandtl state at 9 that correspond to 1400k.

h9 = 1515.42kj/kg

Pr = 450.5

Prandtl expression at state 10

P= p10/p9×pr

=1/8(450.5)

=56.31

Enthalpy at state 10 corresponding to prandtl 56.31

h10 = 860.39kj/kg

At 520k

h11 = 523.63kj/kg

4 0
3 years ago
Other questions:
  • 2. A Class B fire includes burning:
    8·1 answer
  • Write a program with total change amount as an integer input, and output the change using the fewest coins, one coin type per li
    15·1 answer
  • Energy is generated uniformly in a 6 cm thick wall. The steady-state temperature distribution
    11·1 answer
  • In order to reduce the waiting time further, a traffic light was installed to replace the yield sign. Assuming the departure pro
    5·1 answer
  • A 2.5 m-high, 4-m-wide, and 80-cm-thick wall of a house has a thermal resistance of 0.0125°c/W. The thermal conductivity of the
    8·1 answer
  • Bridge Reflection:
    10·1 answer
  • Which of the following values is equivalent to the pound used by the U.S. customary system?
    10·2 answers
  • 1 point
    6·1 answer
  • Who here likes to play project gotham racing?<br> will mark brainlyest
    8·2 answers
  • ceramics must be heated in order to harden the clay and make it durable. the equipment used to heat the clay
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!