When compiling my code I receive this error.
1>MSVCRTD.lib(crtexe.obj) : error LNK2019: unresolved external symbol _main referenced in function ___tmainCRTStartup 1>C:\Users\Gabe Phelan\Documents\Visual Studio 2013\Projects\PA3 test\Debug\PA3 test.exe : fatal error LNK1120: 1 unresolved externals
#include <iostream>
#include <vector>
using namespace std;
class Heap{
private:
vector<int> heap;
int size;
public:
Heap(bool x);
};
#include "Header.h"
Heap::Heap(bool order){
int dummy = 0;
heap.push_back(dummy);
size = heap.size() - 1;
}
You have to have have an entry point, which is a function called main. So you need this,
You dont declare classes in this, but what you want the program to execute.