I have a simple project:
method.h:
#pragma once
#ifdef _METHOD_
#define _METHOD_
#include <stdio.h>
#include <conio.h>
int plus(int a, int b);
#endif // _METHOD_
method.cpp:
#include "method.h"
int plus(int a, int b)
{
return a+b;
}
Source.cpp:
#include <stdio.h>
#include <conio.h>
#include "method.h"
void main()
{
int a = plus(4, 5);
printf("%d",a);
printf("\n");
_getch();
}
but when I build project, an error occure:
I'm a newbie in C programming. And so sorry about my grammar mistakes