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
vekshin1
3 years ago
5

Design and write an object-oriented program for managing inventory bins in a warehouse. To do this you will use two classes: Inv

Bin and BinManager. The InvBin class holds information about a single bin. The BinManager class will own and manage an array of InvBin objects. Here is a skeleton of what the InvBin and BinManager class declarations should look like:
class InvBin

{

private:

string description;

int qty;

public:

InvBin (string d = "empty", int q = 0)

{

description = d;

qty = q;

}

void setDescription(string d);

string getDescription() ;

void setQty(int q);

int getQty( ) ;

};



class BinManager

{

private:

InvBin bin[30];

int numBins;

public:

BinManager()

{

numBins = 0;

}

BinManager(int size, string d[], int q[])

{

}

string getDescription(int index);

int getQuantity(int index);

string displayAllBins();

bool addParts(int binIndex, int q);

bool removeParts(int binIndex, int q);

};
Computers and Technology
1 answer:
andrew11 [14]3 years ago
3 0

Answer:

#include <cstdlib>

#include <iostream>

using namespace std;

int main(int argc, char *argv[])

{

class InvBin {

private:

string description;

int qty;

 

public:

InvBin(){ description = ""; qty = 0;}

InvBin (string d, int q) { description = d; qty = q;}

void setDescription (string d){description = d;}

void setQty(int q){qty = q;}

string getDescription() {return description;}

int getQty(){ return qty; }

};

class BinManager {

private:

InvBin bin[30];

int numBins;

 

public:

BinManager() {numBins=0;}

BinManager(int size, string d[], int q[])

{

int i;

for(i=0; i<size; ++i)

{

bin[i].setDescription(d[i]);

bin[i].setQty(q[i]);

}

numBins = size;

}

void setDescription (int b, string d) {bin[b].setDescription(d); }

void setQty(int b, int q) { bin[b].setQty(q); }

string getDescription(int b) { return bin[b].getDescription();}

int getQty(int b) { return bin[b].getQty();}

bool addParts(int b, int q)

{

int temp;

if(q < 1)

return false;

else

{

temp = bin[b].getQty() + q;

bin[b].setQty(temp);

return true;

}

}

bool removeParts(int b, int q)

{

int temp;

if (q < 1 || bin[b].getQty() < q)

return false;

else

{

temp = bin[b].getQty() - q;

bin[b].setQty(temp);

return true;

}

string displayAllBins()

{

int i;

for(i=0;i<numBins;++i)

cout << i+1 << ". " << left<< setw(20) << bin[i].getDescription()

<< right << setw(4) << bin[i].getQty() << endl;

}

};

system("PAUSE");

return EXIT_SUCCESS;

}

Explanation:

You might be interested in
Even though the Pizza Hut corporation understood the need to make use of the Web, the franchise owners were skeptical. From an I
Gelneren [198K]

Answer:

Franchise owners are essential stakeholder group whose opinions are directly related to the company's success.

Explanation:

Franchise owners are essential stakeholder groups. A stakeholder is a person, organization, social group. A stakeholder can be internal or external to the business. Stakeholders affected by business and affect the business.

Different type of stakeholder is

  • Customer
  • Employees
  • Investors
  • Suppliers
  • Owners

Pizza Hut corporation owner is a stakeholder whose opinions are related to the company's success.

8 0
4 years ago
What actions are considered positive body language?
Ainat [17]

Answer:

Greeting with a smile, open handed gestures, and making eye contact

Explanation:

I used this on E2020 and got it right

5 0
3 years ago
In a typical system design specification, the _____ section describes the constraints, or conditions, affecting a system, includ
Lapatulllka [165]

Answer:

The answer is "Option B".

Explanation:

The system environment includes all software external areas, which may vary from user to user. The System may be different, but it is part of the System environment, depending on the level of available memory. This environment is a part of the System development life cycle. and other options that are not correct which can be described as follows:

  • In option a, Time and cost estimates are part of the SDLC. It is a part where we calculate the overall cost and time for making any new software.
  • In option c, It is not a use in system environment it is reported.
  • In option d, System Components are a hardware device that by system environment for making a system environment but it does not include systems security that's why it is not correct.
6 0
3 years ago
Web-based e-mail like Hotmail is an example of three-tier client-server architecture that provides access to e-mail messages. Tr
Ksju [112]

Answer:

True

Explanation:

The are two client-server architectures, they are, two-tier and three-tier client-server architectures. The two-tier has two layers of communication, they are the presentation and data processing layers. The three-tier architecture adds a third layer called application logic to the middle. The layers can also be called access, distribution and core layers respectively.

Hotmail is a web based emailing system that is designed following the three-tier client-server architecture. It was launched by Microsoft in 1996 and provides users with access to emails with segment core access.

7 0
3 years ago
Computers and other technologies perform a great deal of work today, reducing the need for workers with special expertise. As a
Veronika [31]

Answer: deskilling

Explanation: Deskilling is the process by which skilled labor within an industry or economy is abolished by the introduction of technologies operated by semi skilled or unskilled labourers .

5 0
3 years ago
Other questions:
  • Jeff wants to print quickly so he presses the Ctrl and the P. Jeff used a _____. macro invoice template shortcut
    15·1 answer
  • You need to perform maintenance on a router and need to temporarily reroute traffic through another office. which would be the b
    6·1 answer
  • The UNIX operating system started the concept of socket which also came with a set of programming application programming interf
    12·1 answer
  • Generate an array x that has n=100 random numbers that are uniformly distributed over the interval [0,1) . Look up how to use th
    8·1 answer
  • Working together, printer A and printer B would finish the task in 24 minutes. Printer A alone would finish the task in 60 minut
    8·1 answer
  • Richard needs to copy information from another slide presentation that uses a different design template. To ensure that the info
    7·1 answer
  • Which question can most help a writer revise an argumentative essay?
    9·2 answers
  • What are specific and relevant terms that will help you locate information using an internet search engine?
    10·1 answer
  • Photo editing software, desktop publishing, email and word processing software is most likely to be used by:
    12·1 answer
  • What year did apple computer introduce the first ipod?.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!