Menu
support@nursinghomework.org
+1 714-215-3097

(Solved) : Using C Im Trouble Cout Statment Print Call Cpp File Fix Following Code Must Way 1 Header Q35581628

using c++ im having trouble having my cout out statment printwhen i call it to my cpp file fix the following code so that when ido …..must be this way have 1 header and 1 cppfile ….i wouldlike it explained too.

1)calling the header file

2)then call that fuction it prints out hi

this is my header file below

#ifndef HEADER_H
#define HEADER_H
using namespace std;
#include<string>
#include <algorithm>
#include <stdlib.h>
#include <time.h>
#include <iostream>
class deckQueue {
   string printdeck() {};
};
string deckQueue::printdeck() {
   cout << “hi” << endl;
}

the following below is my cpp file

#include “pch.h”
#include “Header.h”
#include <iostream>
using namespace std;

#include <algorithm>
#include<string>
int main()
{
   deckQueue q;
   q.printdeck;
   //deckQueue * myX = new deckQueue;
   //myX->printdeck();
}

Leave a Reply

Your email address will not be published. Required fields are marked *