Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Entropy Evaluation method for Bulls and Cows game
Search
Hongyi Shen
October 17, 2014
Programming
1
240
Entropy Evaluation method for Bulls and Cows game
AI midterm presentation
Hongyi Shen
October 17, 2014
Tweet
Share
More Decks by Hongyi Shen
See All by Hongyi Shen
How Rsync works
wilbeibi
1
230
Are Bookstores Dying?
wilbeibi
0
66
A Little SVM ( Simple Chinese)
wilbeibi
0
120
Other Decks in Programming
See All in Programming
「今のプロジェクトいろいろ大変なんですよ、app/services とかもあって……」/After Kaigi on Rails 2024 LT Night
junk0612
5
2.1k
CSC509 Lecture 12
javiergs
PRO
0
150
Content Security Policy入門 セキュリティ設定と 違反レポートのはじめ方 / Introduction to Content Security Policy Getting Started with Security Configuration and Violation Reporting
uskey512
1
520
EventSourcingの理想と現実
wenas
6
2.3k
イベント駆動で成長して委員会
happymana
1
310
Streams APIとTCPフロー制御 / Web Streams API and TCP flow control
tasshi
2
350
3rd party scriptでもReactを使いたい! Preact + Reactのハイブリッド開発
righttouch
PRO
1
600
JavaでLチカしたい! / JJUG CCC 2024 Fall LT
nhayato
0
140
ヤプリ新卒SREの オンボーディング
masaki12
0
120
詳細解説! ArrayListの仕組みと実装
yujisoftware
0
570
.NET のための通信フレームワーク MagicOnion 入門 / Introduction to MagicOnion
mayuki
1
720
距離関数を極める! / SESSIONS 2024
gam0022
0
250
Featured
See All Featured
Why Our Code Smells
bkeepers
PRO
334
57k
Java REST API Framework Comparison - PWX 2021
mraible
PRO
28
8.2k
YesSQL, Process and Tooling at Scale
rocio
169
14k
Speed Design
sergeychernyshev
24
610
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5k
Bootstrapping a Software Product
garrettdimon
PRO
305
110k
The Illustrated Children's Guide to Kubernetes
chrisshort
48
48k
GraphQLの誤解/rethinking-graphql
sonatard
67
10k
For a Future-Friendly Web
brad_frost
175
9.4k
Building Better People: How to give real-time feedback that sticks.
wjessup
364
19k
Statistics for Hackers
jakevdp
796
220k
Building Adaptive Systems
keathley
38
2.3k
Transcript
Bulls and Cows solutions Hongyi Shen
[email protected]
‣ key property: symmetric ‣ how to make next guess
‣ entropy evaluation ! ‣ five guess algorithm
target: guess: 0123 0364 1A1B 0213 4075 9138 5421 0123
0364 … … 1A1B 0A2B 0A1B 0A1B 4A0B 1A1B ?A?B ‣ key property: symmetric
Guess the one that would eliminate the most possibilities. ‣
Entropy evaluation map each guess to a possible group, choose the group with maximum entropy ‣ Five-guess algorithm use minimax tech to score each guess, choose the one might eliminate the most possibilities ‣ How to make next guess
3 digits, 0~5 ‣ Entropy evaluation
Rounds Complexity Entropy 5.31 O(m^2). Five-guess < 5.31 O(n^2). Random
guess 5.63 O(1). ‣ Performance VJGQTGVKECNNKOKV
Reference:! ! The Computer As Master Mind by Donald E.
Knuth! ! Mastermind as test-bed for search algorithms by J.H. O'Geran etc.! ! Strategies for playing MOO, or “Bulls and Cows” by John Francis Thanks