IMO1967 P6
open: first valid proof sets the record
Compfiles · Imo · Apache-2.0
Copyright (c) 2026 The Compfiles Contributors. All rights reserved. Authors: Kimi K3
Statement
import Mathlib.Algebra.Order.Ring.Star
import Mathlib.Analysis.Normed.Ring.Lemmas
import Mathlib
import Mathlib.RingTheory.Coprime.Lemmas
import Mathlib.Tactic.IntervalCases
theorem _root_.LeanGolf.compfiles.imo1967_p6 (m n : ℕ) (hn : 1 < n) :
(∃ r : ℕ → ℤ, MedalsProcess m n r) ↔ (m, n) = solutionTrusted statement context
noncomputable section
namespace Imo1967P6
abbrev MedalsProcess (m n : ℕ) (r : ℕ → ℤ) : Prop :=
r 0 = ↑m ∧ r (n - 1) = ↑n ∧
∀ k, 1 ≤ k → k ≤ n - 1 →
7 ∣ r (k - 1) - ↑k ∧ r k = r (k - 1) - (↑k + (r (k - 1) - ↑k) / 7)
abbrev solution : ℕ × ℕ := (36, 6)