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
yaroslaw [1]
3 years ago
8

he Animal Insurance Company:Writes a program that repeatedly prints the insurance fee to pay for a pet according to the followin

g rules: A dog that has been neutered costs $50. A dog that has not been neutered costs $80. A cat that has been neutered costs $40. A cat that has not been neutered costs $60. A bird or reptile costs $10. Any other animal generates an error message.
Engineering
1 answer:
nordsb [41]3 years ago
4 0

Answer:

Program code is given below.

Explanation:

#include <iostream>

using namespace std;03

int main()

{

char neutered, opselect, animal;

const int dogcost = 80, catcost = 60, birdOrReptilecost = 0;

cout << "What kind of animal do you have?\n";

cout << "d for dog, c for cat, b for bird or reptile and o for others.\n\n";

cin >> animal;

cout << "Answer the following questions\n";

cout << "With Y for yes or N for no.\n\n";

cout << "Is your pet neutered? ";

cin >> neutered;

cout << "Enter a select code: ";

cout << "\n1)A dog that has been neutered: ";

cout << "\n2)A dog that has not been neutered: ";

cout << "\n3)A cat that has been neutered costs: ";

cout << "\n4)A cat that has not been neutered costs: ";

cout << "\n5)A bird or reptile: ";

cin >> opselect;

switch (opselect)

{

  case 1:

    cout << "The price for dog that has been neutered is " << dogcost - 30;

    break;

  case 2:

    cout << "The price for dog that has not been neutered is " << dogcost << endl;

   break;

  case 3:

    cout << "The price for cat that has been neutered is " << catcost - 20 << endl;

   break

  case 4:

    cout << "The price for cat that has not been neutered is " << catcost << endl;

   break;

  case 5:

    cout << "The price for bird or reptile is " << birdOrReptilecost << endl;

break;

return 0;

}

You might be interested in
Write a program to input 6 numbers. After each number is input, print the biggest of the numbers entered so far.
likoan [24]

Answer:

P<u>rogram:</u>

# Enter Numbers #

number1 = int(input("Enter number: " ))

print("Largest: " + string(number1))

#for num 2 #

number2 = int(input("Enter a number: "))

if number2 > number1:

 print("Largest: " + string(number2))

else:

 print("Largest: " + string(num1))

#for num 3 #

number3 = int(input("Enter a number: "))

print("Largest: " + string(max(number1, number2, number3)))  

#for num 4 #

number4 = int(input("Enter a number: "))

print("Largest: " + string(max(number1, number2, number3, number4)))

#for num 5 #

number5 = int(input("Enter a number: "))

print("Largest: " + string(max(number1, number2, number3, number4, number5)))

#for num 6 #

number6 = int(input("Enter a number: "))

print("Largest: " + string(max(number1, number2, number3, number4, number5, number6)))        

# END #

4 0
3 years ago
I will Brainlist<br> "Burning and Inch". Describe this measurement.
MAVERICK [17]

Answer:

what measurement

Explanation:

8 0
3 years ago
Read 2 more answers
A missile flying at high speed has a stagnation pressure and temperature of 5 atm and 598.59 °R respectively. What is the densit
alexdok [17]

Answer:

5.31\frac{kg}{m^3}

Explanation:

Approximately, we can use the ideal gas law, below we see how we can deduce the density from general gas equation. To do this, remember that the number of moles n is equal to \frac{m}{M}, where m is the mass and M the molar mass of the gas, and the density is \frac{m}{V}.

For air M=28.66*10^{-3}\frac{kg}{mol} and \frac{5}{9}R=K

So, 598.59 R*\frac{5}{9}=332.55K

pV=nRT\\pV=\frac{m}{M}RT\\\frac{m}{V}=\frac{pM}{RT}\\\rho=\frac{pM}{RT}\\\rho=\frac{(5atm)28.66*10^{-3}\frac{kg}{mol}}{(8.20*10^{-5}\frac{m^3*atm}{K*mol})332.55K}=5.31\frac{kg}{m^3}

7 0
4 years ago
A rigid, well-insulated tank of volume 0.9 m is initially evacuated. At time t = 0, air from the surroundings at 1 bar, 27°C beg
Eva8 [605]

Answer:

\dot{w}= -0.303 KW

Explanation:

This is the case of unsteady flow process because properties are changing with time.

From first law of thermodynamics for unsteady flow process

\dfrac{dU}{dt}=\dot{m_i}h_i+\dot{Q}-\dot{m_e}h_i+\dot{w}

Given that tank is insulated so\dot{Q}=0 and no mass is leaving so

\dot{m_e}=0

\int dU=\int \dot{m_i}h_i\ dt-\int \dot{w}\ dt

m_2u_2-m_1u_1=(m_2-m_1)h_i- \dot{w}\Delta t

Mass conservation m_2-m_1=m_e-m_i

m_1,m_2 is the initial and final mass in the system respectively.

Initially tank is evacuated so m_1=0

We know that for air u=C_vT ,h=C_p T,P_2v_2=m_2RT_2

m_2=0.42 kg

So now putting values

0.42 \times 0.71 \times 730=0.42\times 1.005\times 300- \dot{w} \times 300

\dot{w}= -0.303 KW

3 0
4 years ago
When brazing, the lowest effective brazing temperatures possible should be used to minimize the effects of heat on the base meta
nordsb [41]

Answer:

False

Explanation:

5 0
3 years ago
Other questions:
  • Twenty-five wooden beams were ordered or a construction project. The sample mean and he sample standard deviation were measured
    6·1 answer
  • A Scalar can only be a positive quantity that has a magnitude but no direction ? a)-True b)-False
    5·1 answer
  • Which is the correct order for handwashing
    11·2 answers
  • A lake with a surface area of 525 acres was monitored over a period of time. During onemonth period the inflow was 30 cfs (ie. f
    5·1 answer
  • Water is flowing in a metal pipe. The pipe OD (outside diameter) is 61 cm. The pipe length is 120 m. The pipe wall thickness is
    9·1 answer
  • First person to tell me what this car is gets 10 points
    10·2 answers
  • Who is???????????????????
    13·1 answer
  • Dalton needs to prepare a close-out report for his project. Which part of the close-out report would describe
    6·1 answer
  • La iluminación de la superficie de un patio amplio es 1600 lx cuando el ángulo de elevación del sol 53°. Calcular la iluminación
    15·1 answer
  • 3. It's
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!