mirror of
https://bitbucket.org/Mattrixwv/projecteulercpp.git
synced 2025-12-06 17:13:59 -05:00
Changed exception to Unsolved to fit with naming convention
This commit is contained in:
@@ -76,7 +76,7 @@ void Problem25::reset(){
|
||||
std::string Problem25::getString() const{
|
||||
//If the problem hasn't been solved throw an exception
|
||||
if(!solved){
|
||||
throw unsolved();
|
||||
throw Unsolved();
|
||||
}
|
||||
|
||||
std::stringstream results;
|
||||
@@ -89,7 +89,7 @@ std::string Problem25::getString() const{
|
||||
mpz_class Problem25::getNumber() const{
|
||||
//If the problem hasn't been solved throw an exception
|
||||
if(!solved){
|
||||
throw unsolved();
|
||||
throw Unsolved();
|
||||
}
|
||||
return number;
|
||||
}
|
||||
@@ -98,7 +98,7 @@ mpz_class Problem25::getNumber() const{
|
||||
std::string Problem25::getNumberString() const{
|
||||
//If the problem hasn't been solved throw an exception
|
||||
if(!solved){
|
||||
throw unsolved();
|
||||
throw Unsolved();
|
||||
}
|
||||
return number.get_str();
|
||||
}
|
||||
@@ -107,7 +107,7 @@ std::string Problem25::getNumberString() const{
|
||||
mpz_class Problem25::getIndex() const{
|
||||
//If the problem hasn't been solved throw an exception
|
||||
if(!solved){
|
||||
throw unsolved();
|
||||
throw Unsolved();
|
||||
}
|
||||
return index;
|
||||
}
|
||||
@@ -116,7 +116,7 @@ mpz_class Problem25::getIndex() const{
|
||||
std::string Problem25::getIndexString() const{
|
||||
//If the problem hasn't been solved throw an exception
|
||||
if(!solved){
|
||||
throw unsolved();
|
||||
throw Unsolved();
|
||||
}
|
||||
return index.get_str();
|
||||
}
|
||||
@@ -125,7 +125,7 @@ std::string Problem25::getIndexString() const{
|
||||
uint64_t Problem25::getIndexInt() const{
|
||||
//If the problem hasn't been solved throw an exception
|
||||
if(!solved){
|
||||
throw unsolved();
|
||||
throw Unsolved();
|
||||
}
|
||||
return index.get_ui();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user