When I go to compile this code it says it expected an unqualified-id before the ) in my constructor
analysis2.h:
#ifndef _ANALYSIS2_H
#define _ANALYSIS2_H
class Analysis2{
public:
Analysis2();
...
analysis2.cpp:
#include "analysis2.h"
using namespace std;
Analysis2()
{
Seconds_v = 0;
Seconds_t = 0;
}
...
How do I fix this?
In analysis2.cpp you need to tell the compiler that you are defining the constructor by giving it a scope:
Analysis2::Analysis2()
{
Seconds_v = 0;
Seconds_t = 0;
}
Scope Resolution Operator
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With