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
fiasKO [112]
2 years ago
13

Write a function named “createPurchaseOrder” that accepts the quantity (integer), the cost per item(double), and the description

(string). It will return a newly created PurchaseOrderobject holding that information if they are valid: quantity and cost per item cannot be negative and the description can not be empty or blank(s). When it is invalid, it will return NULL to indicate that it cannot create such PurchaseOrderobject.
Computers and Technology
1 answer:
Leona [35]2 years ago
4 0
#include
Program: using namespace std;
string createPurchaseOrder0;
int main(
{
cout<return 0;
}
string createPurchaseOrder(
{
int qty;
double costPerltem;
string description,info="":
cout<<"Enter Quantity:
cin>>qty;
cout<<"Enter cost per item: "
cin>>costPerltem;
cout<<"Enter Description: "
cin>>description;
if(qty<0 I| costPerltem<0
Idescription.compare(''"')==0)
cout<<'InThe entered data is invalid!":
info="":
else
"
cout<<"'InThe entered data is valid!":
info=info+"'(nQuantity: "+to_string (qty) +" In";
info=info+"Cost per item:
"†to_string (costPerltem)+"In";
info=info+"Description: "description+" In";
return info;

Output:
You might be interested in
This technology was developed in the 1980s and was a successful attempt to provide services for voice, video, and video traffic
sveticcg [70]

Answer:

SONET was the only one on the list created near the 1980s (1985)

Good luck!

<em>~Awwsome</em>

8 0
3 years ago
it says i have brainly plus subscripton but whenever i log onto brainly using my laptop, it says i don't have brainly plus and w
Sladkaya [172]

Answer:

Explanation:

I think you can try logging out from your account. Try cancelling your subscription. Before you do that, reach out to Brainly support.

4 0
3 years ago
A company needs to store its documents in one place, share news and information with all staff, and allow access for employees w
Alenkasestr [34]
C - An Intranet will give access to all employees within the company, whether they work from home or at the office.
4 0
3 years ago
Read 2 more answers
What e-reader technology males a screen that is easy to read and extends battery life
lidiya [134]
I personally use the Kindle Paperwhite series, but any with an E-ink display will work great, as the display isn't very battery-consuming.
6 0
3 years ago
The structure and organization of data in a database is called a data ____.
Aleks [24]
Answer:  "hierarchy" .
_____________________________________________________
6 0
3 years ago
Other questions:
  • We can see spreadsheet results graphically by creating:
    15·1 answer
  • A(n) ____________________ or cryptosystem is an encryption method or process encompassing the algorithm, key(s) or cryptovariabl
    11·1 answer
  • Bullets in a text box will do which of the following?
    9·2 answers
  • Your essay is due tomorrow and you don't have time to write it. You decide to buy an essay online. You've paid for it, so it can
    12·1 answer
  • Given the three side lengths, how can you tell if a triangle<br>is a right triangle?​
    5·1 answer
  • ____ is a method of querying and reporting that takes data from standard relational databases, calculates and summarizes the dat
    11·1 answer
  • What two protocols are used for remote access to a server, using unencrypted and encrypted transmissions respectively? answer
    13·1 answer
  • You are setting up a small network. The customer has decided to change his internet service provider (ISP) to EtherSpeed. The IS
    9·1 answer
  • You can't cite Wikipedia, what are three ways that you can use it for your research?
    5·1 answer
  • Consider a game that is searched using random restart hill climbing strategy. Assume that the success rate for the game is 25%.
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!