error LNK1561: entry point must be defined - I have received this error after build solution on my program that I am trying to complete for my class on converting work hours to work days. Any suggestions of why I would get this error?
NumDays.h
// Specification file for the NumDays class
#ifndef NUMDAYS_H
#define NUMDAYS_H
class NumDays
{
private:
int days; // To hold a number of days
int hours; // To hold a number of hours
void simplify(); // Defined in NumDays.cpp
public:
// Constructor
NumDays(int f = 0, int i = 0)
{
days = f;
hours = i;
simplify();
}
// Implementation file for the NumDays class
#include <cstdlib> // Needed for abs()
#include "NumDays.h"
//*****************************************************************
// Definition of member function simplify. This function *
// checks for values in the hours member greater than *
// eight or less than zero. If such a value is found, *
// the numbers in days and hours are adjusted to conform *
// to a standard worked days & hours expression. For example, *
// 8 hours would be converted to 1 day, 12 hours would be *
// converted to 1.5 days and 18 hours converted to 2.25 days. *
//*****************************************************************
void NumDays::simplify()
{
if (hours >= 8)
{
days += (hours / 8);
hours = hours % 8;
}
else if (hours < 0)
{
days -= ((abs(hours) / 8) + 1);
hours = 8 - (abs(hours) % 8);
}