This seemed pretty simple to me.

#include <iostream.h>
#include <string.h>

class thecounter{
private: static int maxlen;
char input[maxlen];

public: thecounter(int c)
{maxlen=c}
void setText()
{
do{
cout<<"Enter whatever, as long as it is no more than ";
cout<<maxlen<<" characters including spaces.\n";
cin.getline(input,(--maxlen));
if(int check = (strlen(input)>(--maxlen)){
cout<<"Error! I said no more than "<<maxlen<<"!";
cout<<"Re-enter text.";
cin.getline(input,(--maxlen));
}
} while(check !=0);
}
static int NumberOfSentances;
static int NumberOfWords;
static int NumberOfLetters;
void textCount()
{
for(int i=0;i<maxlen;i++){
if(isalnum(input[i]))
NumberOfLetters++;
if(isspace(input[i]))
NumberOfWords++;
if(ispunct(input[i]))
NumberOfSentances;
}
}
void show()
{
cout<<"There are "<<NumberOfSentances<<"sentances."
cout<<"There are "<<NumberOfWords<<"words."
cout<<"There are "<<NumberOfLetters<<"letters."
}
};

void main(){
thecounter first=100,second=200,third=300;
first.setText();
first.textCount();
first.show();
second.setText();
second.textCount();
second.show();
third.setText();
third.textcount();
third.show();
}

All I want to do, is have a class that can
count the number of letters, words, and sentances
in a text entered by the user. I used some macros
to figure out whats what. But I am getting about 12
errors, and I don`t know what they mean. It says
that the varible "maxlen" should be a const int, but
then I can`t use different length text strings. Any
ideas?