mirror of
https://bitbucket.org/Mattrixwv/projecteulercpp.git
synced 2025-12-06 17:13:59 -05:00
Added results to 38
This commit is contained in:
@@ -33,8 +33,8 @@ private:
|
|||||||
//Static variables
|
//Static variables
|
||||||
static int HIGHEST_POSSIBLE_NUM; //The highest number that needs to be checked for a 1-9 pandigital
|
static int HIGHEST_POSSIBLE_NUM; //The highest number that needs to be checked for a 1-9 pandigital
|
||||||
//Instance variables
|
//Instance variables
|
||||||
uint64_t largestNum;
|
uint64_t largestNum; //The number passed to the executeFormula function that returns the largest pandigital
|
||||||
uint64_t pandigital;
|
uint64_t pandigital; //The largest pandigital number found
|
||||||
//Functions
|
//Functions
|
||||||
std::string executeFormula(int num); //Take the number and add its multiples to a string to return
|
std::string executeFormula(int num); //Take the number and add its multiples to a string to return
|
||||||
public:
|
public:
|
||||||
@@ -49,3 +49,8 @@ public:
|
|||||||
uint64_t getLargestNum() const; //Returns the largest number
|
uint64_t getLargestNum() const; //Returns the largest number
|
||||||
uint64_t getPandigital() const; //Returns the pandigital of the number
|
uint64_t getPandigital() const; //Returns the pandigital of the number
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/* Results:
|
||||||
|
The largest appended product pandigital is 932718654
|
||||||
|
It took 740.729 microseconds to solve this problem.
|
||||||
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user