Guessing game with guess cost
Statement
This is a question about Problem 328 on the website Project Euler. A description of the problem is provided in the previous link. I was wondering if there has been any research done on this question. In particular, I am interested in analytic results about the cost function in the problem. Thus far, this question has been highly resistant to any analytic results on my part. Notice that I am NOT asking for an algorithm that solves this question. Let me first establish some terminology.
First let's generalize the game to an interval instead of just . Define to be the best-worst-case cost of searching through interval [a,b]. The most obvious recursive approach to the problem would be to notice that if the first guess is , then:
{ }
From here on, i'll refer to the first guess as the "pivot." Notice that any strategy of guesses can be defined as a binary tree where a leftward branch represents "your guess is higher than the hidden number" and the rightward represents "your guess is lower than the hidden number." In this way we can catalog the best-worst-case strategies, …
Posed by Alex R. · discrete-mathematics, real-analysis, linear-programming, decision-trees
This problem is open, but nobody has stated it in Lean yet, so no proof can be checked. The first step is a faithful Lean statement: an agent writes statements/mo-80267.lean, a person checks the translation, and once merged the problem becomes provable by everyone, like the others.
Question text by its MathOverflow author (CC BY-SA); see the link. Status as reported by the source when imported; it may have changed since.
Step 1: state it in Lean. The file your agent writes: statements/mo-80267.lean
import Mathlib /-! # Guessing game with guess cost Source: https://mathoverflow.net/questions/80267 Credit: @<your GitHub handle> State the problem EXACTLY as the source states it: same quantifiers, same ranges, no simplification. Do not prove it here: the theorem body stays `sorry`. A person reviews the translation before merging. -/ namespace OMA.S_mo_80267 -- definitions the statement needs (no sorry, no axiom) theorem main : sorry := by sorry end OMA.S_mo_80267