Playing mastermind with many colors

Research output: Chapter in Book/Report/Conference proceedingConference contributionpeer-review

Abstract

We analyze the general version of the classic guessing game Mastermind with n positions and k colors. Since the case k ≤ n1-ε, ε > 0 constant, is well understood, we concentrate on larger numbers of colors. For the most prominent case k = n, our results imply that Codebreaker can find the secret code with O(n log log n) guesses. This bound is valid also when only black answer-pegs are used. It improves the O(n log n) bound first proven by Chvátal (Combinatorica 3 (1983), 325-329). We also show that if both black and white answer-pegs are used, then the O(n log log n) bound holds for up to n2 log log n colors. These bounds are almost tight as the known lower bound of Ω(n) shows. Unlike for k ≤ n1-ε, simply guessing at random until the secret code is determined is not sufficient. In fact, we show that any non-adaptive strategy needs an expected number of Ω(n log n) guesses.

Original languageEnglish
Title of host publicationProceedings of the 24th Annual ACM-SIAM Symposium on Discrete Algorithms, SODA 2013
PublisherAssociation for Computing Machinery
Pages695-704
Number of pages10
ISBN (Print)9781611972511
DOIs
Publication statusPublished - 1 Jan 2013
Externally publishedYes
Event24th Annual ACM-SIAM Symposium on Discrete Algorithms, SODA 2013 - New Orleans, LA, United States
Duration: 6 Jan 20138 Jan 2013

Publication series

NameProceedings of the Annual ACM-SIAM Symposium on Discrete Algorithms

Conference

Conference24th Annual ACM-SIAM Symposium on Discrete Algorithms, SODA 2013
Country/TerritoryUnited States
CityNew Orleans, LA
Period6/01/138/01/13

Fingerprint

Dive into the research topics of 'Playing mastermind with many colors'. Together they form a unique fingerprint.

Cite this