File size: 290 Bytes
d3791e3 | 1 2 3 4 5 6 7 8 9 | import Mathlib
/-- The polynomial is congruent to the stated residue. -/
theorem congr_poly (x : ℤ) (h : x ≡ 5 [ZMOD 6]) :
6 * x ^ 2 + 3 * x + 5 ≡ 2 [ZMOD 6] := by
have h1 := (((h.pow 2).mul_left 6).add ((h).mul_left 3)).add_right 5
refine h1.trans ?_
norm_num [Int.ModEq]
|