# Hi I am using Repl.it, could anyone help fix the errors? Instruction: main.cpp include <iostream> include...

###### Question:

Hi I am using Repl.it, could anyone help fix the errors?

Instruction:

main.cpp

include <iostream>
include <cstdlib>
include "InvItem.h"
using namespace std;

int main() {
InvItem a;
string description, idNumber;

getline(cin, description);
getline(cin, idNumber);

// store properties in the object
a.setDescription(description);
a.setIDNumber(idNumber);

// print out the properties of the object
cout << a.getDescription() << endl;
cout << a.getIDNumber() << endl;

}

--------------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------

invltem.h

ifndef INVITEM_H
define INVITEM_H
include<string>
using std::string;

class InvItem
{
public:
InvItem();
void setDescription(string desc);
void setIDNumber(string id);

string getDescription() const;
string getIDNumber() const;
private:
string desc;
string id;
};

endif

-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------

invltem.cpp

include "InvItem.h"
include<string>
using std::string;

InvItem::InvItem(): desc(""), id(""){}
void InvItem::setDescription(string desc){
this->desc =desc;
}
void InvItem::setIDNumber(string id){
this->id=id;
}

string InvItem::getDescription() const{return desc;}
string InvItem::getIDNumber() const{return id;}

-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------​​​​​​​-------

Errors:

$clang version 7.0.0-3~ubuntu0.18.04.1 (tags/RELEASE_700/final) exit status 1 invItem.cpp:1:10: fatal error: 'InvItem.h' file not found include "InvItem.h" ^~~~~~~~~~~ 1 error generated. main.cpp:3:10: fatal error: 'InvItem.h' file not found include "InvItem.h" ^~~~~~~~~~~ 1 error generated.$

​​​​​​​

The code I have given you is correct. The problem is that the include statements are missing. You need to examine the error message you get and put the correct include statements in the files. HINT: If there is an error that some type is not found, and you that type exists, it's a include error. All three files are missing include statements.
blue socks - details Failure reason: Error Teacher's input: Blue Socks 7265517 Error details: exit status 1 invitem.cpp:1:10: fatal error: 'InvItem.h' file not found include "InvItem.h" 1 error generated. main.cpp:3:10: fatal error: 'InvItem.h' file not found include "InvItem.h"

#### Similar Solved Questions

##### How is it that the strong and weak nuclear forces do not have an influence beyond the nucleus of the atom?
How is it that the strong and weak nuclear forces do not have an influence beyond the nucleus of the atom?...
##### In 3-6 sentences, and using some of your own words, explain the connection between morality and...
In 3-6 sentences, and using some of your own words, explain the connection between morality and religion. (Base your answer on the module. but you can also offer your own thoughts). T TT Arial 3(12pt) T EIE...
##### Differential Equations 7. Show that the two solutions y, = e" and y, = e' of...
Differential Equations 7. Show that the two solutions y, = e" and y, = e' of y" + 4y' + 3y = 0 are linearly independent. You need not verify that y, and y, are solutions to the DE. Cite any relevant theorem from the text by theorem number and page number....
##### 42. What should be the primary change in the following screen? ReadySHARE Vault Setup Installing Please...
42. What should be the primary change in the following screen? ReadySHARE Vault Setup Installing Please iait whle ReadySHARE Vault is being installed Checking for ReadySHARE device NETGEAR 2012 < Back dlose Cancel A. B. C. D. Removing the text after installing. Add time to the progress bar Add th...
##### Base on the subjective data and objective data develop a nursing care plan with a nursing...
Base on the subjective data and objective data develop a nursing care plan with a nursing diagnosis, 1 short term goal, 4 nursing interventions with rationales and an evaluation. Subjective Data: Patient stated, “I was on the Grand Central platform on my way to meet with the prophet of the chu...
##### How do you find dy/dx when y=ln(tanx)?
How do you find dy/dx when y=ln(tanx)#?...