# PLS CHECK THE PROGRAM nd correct it

THE QUESTION OF THIS PROGRAM HAS BEEN POSTED UNDER THE TOPIC

/* Program used to compute some statistics of similarity
Standard deviation stdev:
sqrt(( sum of the square of each term - square of mean )/(n-1))
USE MOSS.CPP
-----------------------------------------------------
/*Declaring and initialsing variables*/
#include
#include
#include
#include
#include "Moss.h"
using namespace std;

/*Main function*/
int main()
{
Moss temp;
temp.input_values();
temp.calc();
temp.output_values();

return 0;
}

/*End of program*/

MOSS.CPP
===========================================

#include "Moss.h"
#include
#include
#include

void Moss::input_values()
{
/*Implementing vectors*/
int dummy;
string s;

getline(cin,s,'(');
cin>>dummy;
p1.push_back(dummy);

getline(cin,s,'(');
cin>>dummy;
p2.push_back(dummy);

getline(cin,s,' ');
cin>>dummy;
nline.push_back(dummy);

cout<<p1[0]<<p2[0]<<nline[0];
int n;
cin>>n;
}

/*End*/
MOSS.H
-------------------------------------------

// File: Moss.h
#include
using namespace std;
class Moss {

/*Declaring private and public functions of a class*/
private:
vector p1,p2,nline;

public:
void input_values();
void calc();
void output_values();

};

• :
: THE QUESTION OF THIS PROGRAM HAS BEEN POSTED UNDER THE TOPIC
: QUESTION PLZ HELP ME...C++ ADT
:
: /* Program used to compute some statistics of similarity
: Standard deviation stdev:
: sqrt(( sum of the square of each term - square of mean )/(n-1))
: USE MOSS.CPP
: -----------------------------------------------------
: /*Declaring and initialsing variables*/
: #include
: #include
: #include
: #include
: #include "Moss.h"
: using namespace std;
:
: /*Main function*/
: int main()
: {
: Moss temp;
: temp.input_values();
: temp.calc();
: temp.output_values();
:
: return 0;
: }
:
: /*End of program*/
:
: MOSS.CPP
: ===========================================
:
: #include "Moss.h"
: #include
: #include
: #include
:
: void Moss::input_values()
: {
: /*Implementing vectors*/
: int dummy;
: string s;
:
: getline(cin,s,'(');
: cin>>dummy;
: p1.push_back(dummy);
:
: getline(cin,s,'(');
: cin>>dummy;
: p2.push_back(dummy);
:
: getline(cin,s,' ');
: cin>>dummy;
: nline.push_back(dummy);
:
: cout<<p1[0]<<p2[0]<<nline[0];
: int n;
: cin>>n;
: }
:
: /*End*/
: MOSS.H
: -------------------------------------------
:
: // File: Moss.h
: #include
: using namespace std;
: class Moss {
:
: /*Declaring private and public functions of a class*/
: private:
: vector p1,p2,nline;
:
: public:
: void input_values();
: void calc();
: void output_values();
:
: };
:
:
:
:

wheres the implementation for calc() and output_values()? if you dont intend to do nothing, shouldnt you atleast put the skeletons out there, for the project to atleast link?

void Moss::calc()
{
}

void Moss::output_values()
{
}

the program compiled and linked...add what you need to do in either of the methods and you should be good, for the time being.