Code:
// MAIN FILE
#include "header.hpp"
#include <iostream>
#include <cstdlib>
using namespace std;
int main()
{
{
if (var(1,1,1)==FALSE) cout << "FALSE\n";
else cout << "TRUE\n";
}
system("PAUSE(0)");
return(0);
}
Code:
// Separate unit
#include "header.hpp"
using namespace std;
bool var(short p1, short p2, short p3)
{
if (p1==1&&p2==1&&p3==1) return TRUE;
return FALSE;
}
Code:
// HEADER FILE
#define TRUE true
#define FALSE false
class object
{
private:
short *ptr; // Not in used in example
public:
friend bool var(short,short,short);
object() {}
~object() {}
};