diff --git a/maths/modular_inverse.nim b/maths/modular_inverse.nim index 4b9d0b87..234cb2ab 100644 --- a/maths/modular_inverse.nim +++ b/maths/modular_inverse.nim @@ -67,7 +67,7 @@ when isMainModule: check modularInverse(17, 17).is_none() randomize() - const randomTestSize = 1000 + const randomTestSize = 10 for testNum in 0..randomTestSize: let a = rand(-10000000..10000000) let modulus = rand(1..1000000) diff --git a/strings/check_anagram.nim b/strings/check_anagram.nim index 9a3ef7ba..d3dbdd19 100644 --- a/strings/check_anagram.nim +++ b/strings/check_anagram.nim @@ -59,7 +59,7 @@ func toLowerUnchecked(c: char): char {.inline.} = # 0b100_0001, so setting the sixth bit to 1 gives letter's lowercase pair. char(uint8(c) or 0b0010_0000'u8) -template normalizeChar(c: char) = +template normalizeChar(c: char): char = ## Checks if the character is a letter and lowers its case. ## ## Raises a `ValueError` on other characters.