Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #ifndef ROMAN_INT_H_INCLUDED
- #define ROMAN_INT_H_INCLUDED
- #include <array>
- #include <string>
- #include <cctype>
- #include <iostream>
- #include <stdexcept>
- //------------------------------------------------------------------------------
- const int NO_VALUE = -1;
- class Roman_int {
- public:
- Roman_int() :roman("") {}
- int as_int() const;
- friend std::istream& operator>>(std::istream& is, Roman_int& r);
- friend std::ostream& operator<<(std::ostream& os, const Roman_int& r);
- private:
- std::string roman;
- };
- bool isValidNumeral(std::string& numeral);
- int valueof(const char c);
- #endif // ROMAN_INT_H_INCLUDED
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement