Write a loop that fills a vector v

Assignment Help Chemistry
Reference no: EM13840581

Class Implementation and Vector LoopsPart A

Implement all member functions of the following class:

class Person

{

public:

    Person();

    Person(string pname, int page);

    string get_name() const;

    int get_age() const;

    void set_name(string pname);

    void set_age(int page);

private:

    string name;

    int age;  //0 if unknown

};

Part BWrite a loop that fills a vector V with ten random numbers between 1 and 100. 

Part CWrite a loop that fills a vector V with ten different random numbers between 1 and 100.

Reference no: EM13840581

Questions Cloud

Technological advancements-challenges business and society : Technological Advancements and Challenges" Business and Society. In a departure from its normal business operations Apple has recently teamed up with a bio-tech company to investigate the possibility of cloning human organs. You have been tasked with..
Write a program to sort name and age : Write a program to sort name and age. The program takes input as the 1) first name which can be 2 to 10 characters 2) Data of birth as day, month, and year. The program sorts the name from a to z. The output of your program are 1) sorted names and 2)..
As continuation of your healthcare venture : As a continuation of your healthcare venture, to start up an urgent care center. You want to explore more innovative tools and be able to enhance and optimize your strategies to compete in healthcare.
Most important step in the decision-making process : Why is identification of the real problem the first and most important step in the decision-making process? How does attribution theory explain mistakes that can be made as managers and employees work together to explain why the problem occurred?
Write a loop that fills a vector v : Part BWrite a loop that fills a vector V with ten random numbers between 1 and 100.  Part CWrite a loop that fills a vector V with ten different random numbers between 1 and 100.
Natural law-deontology-utilitarianism and virtue theory : The most common ethical theories applied to health care include: natural law, deontology, utilitarianism, and virtue theory. Which of these theories most closely align to your personal values? Why? Explain your answer.
Motivational theory applications argue : Motivational theory applications argue for recognizing individual differences. They also suggest paying attention to members of diverse groups. Is this a contradiction? Why or why not?
Use both positive and negative reinforcement : If you, as a manager, had to help change an employee’s behavior to make him or her more productive, what course of action would you take? How might you use both positive and negative reinforcement?
Company makes product donations to the school : The following is a quote from a news article: "If a company makes product donations to the school- computers for instance - then the image of a. company goes up as graduate students use the company's products." Does such action consistent with a comp..

Reviews

Write a Review

Chemistry Questions & Answers

  Describe hydrogen gas can be produced in the laboratory

Hydrogen gas can be produced in the laboratory through the reaction of magnesium metal with hydrochloric acid

  Explain the gases are allowed to mix at constant temperature

Consider an apparatus shows gases in two containers and one empty container. When the valves are opened and the gases are allowed to mix at constant temperature, what is the distribution of atoms in each container

  State spectroscopy is a function of the wavelength

Using the information provided below, derive an expression to show that the energy of an electronic transition measured from UV-VIS spectroscopy is a function of the wavelength

  State serine residue on the dual function enzyme

Phosphorylation of a serine residue on the dual function enzyme PFK2/FBP2 switches it from a kinase active, phosphatase inactive form to a kinase inactive, phosphatase active form

  Explain by what factor does the fraction of collisions

Explain by what factor does the fraction of collisions with energy equal to or greater than the activation energy of 100 kj/mol change if the temperature increases from 19C to 59C

  Explain the indicator dilution method is a technique

The indicator dilution method is a technique used to determine flow rates of fluids in channels for which devices like rotameters and orifice meters cannot be used.

  Hydrogen chloride

0.70g of hydrogen chloride (HCl) is dissolved in water to make 6.0L of solution. What is the pH of the resulting hydrochloric acid solution?0.85 g of sodium hydroxide (NaOH) pellets are dissolved in water to make 8.0 L of solution. What is the pH of ..

  Explain a would be removed by four successive extractions

what weight of A would be removed from a solution of 10g of A in 100mL of water by a single extraction of 100mL lingroin. what weight of A would be removed by four successive extractions with 25mL portions of lingroin

  You need to make an aqueous solution of 0180 m sodium

you need to make an aqueous solution of 0.180 m sodium sulfate for an experiment in lab using a 250 ml volumetric

  Explain how many moles of h2o are in the system

An apparataus has three bulbs, a,b, and c. a has h2o, co2, and n2 with a pressure of 564 mmHg, Bulbs b and c are empty. bulb a is 25 degrees celcius, b is -70 celcius and c is -190 celcius. how many moles of h2o are in the system if the stopcock b..

  State water softeners replace these ions with na

Hard water contains Ca2+, Mg 2+, and Fe2+. Water softeners replace these ions with Na+. If 1.0 X 10^3L of hard water contains 0.010 M Ca2+ and 0.0050 M Mg2+

  Explain the esterification of acetic acid in the preparation

Concentrated sulfuric acid is used as a catalyst for the esterification of acetic acid in the preparation of isopentyl acetate. Why is sulfuric acid needed if another acid, acetic acid, is already present

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd