Getting LNK2019 error

#include
#include
using namespace std;

void IntroToTheGame()
{
constexpr int WORD_LENGTH = 5;
cout << “wellcome to Bulls and Cows.\n”;
cout << “can you guess the” << WORD_LENGTH;
cout << " letter isogram i must be thinking of?\n";
cout << endl;
return;
}

this is the code I wrote, its getting some linker error , the error is as follows :

  1. Error LNK2019 unresolved external symbol _main referenced in function “int __cdecl invoke_main(void)” (?invoke_main@@YAHXZ) BullsAndCowsGame C:\Users\HP\source\repos\section_02\BullsAndCowsGame\MSVCRTD.lib(exe_main.obj) 1
  2. unresolved externals

can I be helped where I am wrong?
thanks

You haven’t defined int main() which is required.

1 Like

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms