maybe something wrong with neuron.h?
at which point does the program terminate? (before or after "Quit?" ? You may want to add more input/output to determine more precisely)
neuron created
neuron created
neuron created
m_dat = 2
m_dat = 1
m_dat = 7
m_dat = 0
m_dat = 0
*The program terminates here, without input from user*
Process returned -1073741676 (0xC0000094) execution time : 2.959 s
Press any key to continue.
#include "neuron.h"
neuron::neuron()
{
//ctor
cout << "neuron created" << endl;
m_dat = 5;
}
neuron::~neuron()
{
//dtor
cout << "neuron destroyed" << endl;
}
void neuron::rec1(int a, int b)
{
m_dat = ((m_dat + a) / b);
cout << "m_dat = " << m_dat << endl;
}
void neuron::rec2(int a, int b)
{
m_dat = ((m_dat + a) / b);
cout << "m_dat = " << m_dat << endl;
}
int neuron::send(void)
{
return m_dat;
cout << "m_dat sent" << endl;
}
I had it running fine before, before I put the if statement in. I was trying to keep from memory overrun. At least I think that's what it's called. You know when you try to write a number to an in(for example) variable and there is not enough space in said variable. *BAM* Something goes and gets overwritten. i think I did that once with another program already. My windows right-click menu stopped working. Still trying to fix that one. Geesh!
Thanks for responding again.
Thanks for your help, hamsterman. Somehow I fixed it. It was the way I wrote lines 17 and 22 in neuron.cpp. you were helpful again. :o) I look forward to working with you, next time.