range.h
428 Bytes
#ifndef RANGE_H
#define RANGE_H
#include <exception>
#include <string.h>
#include "aux.h"
struct range
{
int min;
int max;
};
void wrongRange();
range parseRange(char* input, int total);
class rangeException : public exception
{
public:
rangeException(std::string ss) : s(ss) {}
~rangeException() throw () {}
const char* what() const throw() { return s.c_str(); }
private:
string s;
};
#endif