mirror of
https://github.com/TomHarte/CLK.git
synced 2024-12-23 05:29:23 +00:00
Fixed comments.
This commit is contained in:
parent
daafebe7ac
commit
69914faf02
@ -14,13 +14,12 @@
|
||||
|
||||
namespace NumberTheory {
|
||||
/*!
|
||||
@returns The greatest common divisor of @c a and @c b as computed by Euclid's algorithm.
|
||||
@returns The greatest common divisor of @c a and @c b.
|
||||
*/
|
||||
template<class T> T greatest_common_divisor(T a, T b) {
|
||||
#if __cplusplus > 201402L
|
||||
return std::gcd(a, b);
|
||||
#else
|
||||
// TODO: replace with the C++17 GCD function, once available.
|
||||
if(a < b) {
|
||||
std::swap(a, b);
|
||||
}
|
||||
@ -37,8 +36,8 @@ namespace NumberTheory {
|
||||
}
|
||||
|
||||
/*!
|
||||
@returns The least common multiple of @c a and @c b computed indirectly via Euclid's greatest
|
||||
common divisor algorithm.
|
||||
@returns The least common multiple of @c a and @c b computed indirectly via the greatest
|
||||
common divisor.
|
||||
*/
|
||||
template<class T> T least_common_multiple(T a, T b) {
|
||||
if(a == b) return a;
|
||||
|
Loading…
Reference in New Issue
Block a user