• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 02:27
CEST 08:27
KST 15:27
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
RSL Season 1 - Final Week6[ASL19] Finals Recap: Standing Tall12HomeStory Cup 27 - Info & Preview18Classic wins Code S Season 2 (2025)16Code S RO4 & Finals Preview: herO, Rogue, Classic, GuMiho0
Community News
Team TLMC #5 - Submission extension1Firefly given lifetime ban by ESIC following match-fixing investigation17$25,000 Streamerzone StarCraft Pro Series announced7Weekly Cups (June 30 - July 6): Classic Doubles7[BSL20] Non-Korean Championship 4x BSL + 4x China11
StarCraft 2
General
TL Team Map Contest #5: Presented by Monster Energy Team TLMC #5 - Submission extension RSL Revival patreon money discussion thread The GOAT ranking of GOAT rankings Weekly Cups (June 30 - July 6): Classic Doubles
Tourneys
$5,100+ SEL Season 2 Championship (SC: Evo) WardiTV Mondays RSL: Revival, a new crowdfunded tournament series Sparkling Tuna Cup - Weekly Open Tournament FEL Cracov 2025 (July 27) - $8000 live event
Strategy
How did i lose this ZvP, whats the proper response Simple Questions Simple Answers
Custom Maps
External Content
Mutation # 482 Wheel of Misfortune Mutation # 481 Fear and Lava Mutation # 480 Moths to the Flame Mutation # 479 Worn Out Welcome
Brood War
General
A cwal.gg Extension - Easily keep track of anyone Flash Announces Hiatus From ASL [Guide] MyStarcraft BW General Discussion [ASL19] Finals Recap: Standing Tall
Tourneys
[BSL20] Non-Korean Championship 4x BSL + 4x China [Megathread] Daily Proleagues 2025 ACS Season 2 Qualifier Small VOD Thread 2.0
Strategy
Simple Questions, Simple Answers I am doing this better than progamers do.
Other Games
General Games
Nintendo Switch Thread Stormgate/Frost Giant Megathread Path of Exile CCLP - Command & Conquer League Project The PlayStation 5
Dota 2
Official 'what is Dota anymore' discussion
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Heroes of StarCraft mini-set
TL Mafia
TL Mafia Community Thread Vanilla Mini Mafia
Community
General
Russo-Ukrainian War Thread US Politics Mega-thread Summer Games Done Quick 2025! Things Aren’t Peaceful in Palestine The Accidental Video Game Porn Archive
Fan Clubs
SKT1 Classic Fan Club! Maru Fan Club
Media & Entertainment
Movie Discussion! [Manga] One Piece Anime Discussion Thread [\m/] Heavy Metal Thread
Sports
2024 - 2025 Football Thread Formula 1 Discussion NBA General Discussion TeamLiquid Health and Fitness Initiative For 2023 NHL Playoffs 2024
World Cup 2022
Tech Support
Computer Build, Upgrade & Buying Resource Thread
TL Community
The Automated Ban List
Blogs
Men Take Risks, Women Win Ga…
TrAiDoS
momentary artworks from des…
tankgirl
from making sc maps to makin…
Husyelt
StarCraft improvement
iopq
Trip to the Zoo
micronesia
Customize Sidebar...

Website Feedback

Closed Threads



Active: 464 users

A Puzzling Fortnight - Day 7

Blogs > JeeJee
Post a Reply
JeeJee
Profile Blog Joined July 2003
Canada5652 Posts
February 18 2010 16:26 GMT
#1
Let's jump right into it this time.

You vs me. An even numer of coins (potentially different denominations) are arranged in a line between us, going left-to-right. We are going to play the following game:
We take turns taking a coin from either end of the coin line. The game ends when there are no more coins. The winner is the one whose little pile of coins at the end is worth more than the other's. Simple.

You go first. Devise a strategy such that your pile at the end will always at least match my pile in value.

GL!

(\o/)  If you want it, you find a way. Otherwise you find excuses. No exceptions.
 /_\   aka Shinbi (requesting a name change since 27/05/09 ☺)
onmach
Profile Blog Joined March 2009
United States1241 Posts
Last Edited: 2010-02-18 16:50:31
February 18 2010 16:50 GMT
#2
Hmm, my naive approach. If there are 2 coins, pick the largest. If there are 4 or more coins, add up the values of the coin on the left and second coin from the right, and compare that to the value of the second coin to the left and the coin on the right. If the first number is higher, then take a coin from the left side, and if the second is larger take a coin from the right side.
ieatkids5
Profile Blog Joined September 2004
United States4628 Posts
Last Edited: 2010-02-18 17:02:08
February 18 2010 16:55 GMT
#3
11111111
if all the denominations are the same, then just pick whatever

any other scenario, add up every other number starting at one end, then add up every other number starting from the other end. whichever side you start on that has a greater sum, start picking from that side.

example:
43472191

4+4+2+9=19
3+7+1+1=12

start picking from the side with the 4. your opponent has to take the 3 because if he takes the 1, then you will take the 9. after he takes the 3, take the 4. he will take the 7. take the 2. he takes the 1. you take the 9.

another example:
27261192

2+2+1+9=14
7+6+1+2=16

start from the right side and take the 2. your opponent will take the 9 because you will take it if he doesnt. take the 1. opponent will take next 1 because he cannot take the 2 on the left (or you will take the 7. take the 6. opponent takes the 2. take the 7.



edit - updated with examples
onmach
Profile Blog Joined March 2009
United States1241 Posts
February 18 2010 19:15 GMT
#4
Your solution is simpler, and after looking your examples, mine was clearly defective.
JeeJee
Profile Blog Joined July 2003
Canada5652 Posts
Last Edited: 2010-02-18 20:02:13
February 18 2010 19:48 GMT
#5
On February 19 2010 01:55 ieatkids5 wrote:
11111111
if all the denominations are the same, then just pick whatever

any other scenario, add up every other number starting at one end, then add up every other number starting from the other end. whichever side you start on that has a greater sum, start picking from that side.

example:
43472191

4+4+2+9=19
3+7+1+1=12

start picking from the side with the 4. your opponent has to take the 3 because if he takes the 1, then you will take the 9. after he takes the 3, take the 4. he will take the 7. take the 2. he takes the 1. you take the 9.

another example:
27261192

2+2+1+9=14
7+6+1+2=16

start from the right side and take the 2. your opponent will take the 9 because you will take it if he doesnt. take the 1. opponent will take next 1 because he cannot take the 2 on the left (or you will take the 7. take the 6. opponent takes the 2. take the 7.



edit - updated with examples



i assume you re-calculate these 2 values every time it is your turn?

edit
@onmach
which example shows inadequacy of your strategy? curious..
(\o/)  If you want it, you find a way. Otherwise you find excuses. No exceptions.
 /_\   aka Shinbi (requesting a name change since 27/05/09 ☺)
ieatkids5
Profile Blog Joined September 2004
United States4628 Posts
February 20 2010 02:01 GMT
#6
On February 19 2010 04:48 JeeJee wrote:
Show nested quote +
On February 19 2010 01:55 ieatkids5 wrote:
11111111
if all the denominations are the same, then just pick whatever

any other scenario, add up every other number starting at one end, then add up every other number starting from the other end. whichever side you start on that has a greater sum, start picking from that side.

example:
43472191

4+4+2+9=19
3+7+1+1=12

start picking from the side with the 4. your opponent has to take the 3 because if he takes the 1, then you will take the 9. after he takes the 3, take the 4. he will take the 7. take the 2. he takes the 1. you take the 9.

another example:
27261192

2+2+1+9=14
7+6+1+2=16

start from the right side and take the 2. your opponent will take the 9 because you will take it if he doesnt. take the 1. opponent will take next 1 because he cannot take the 2 on the left (or you will take the 7. take the 6. opponent takes the 2. take the 7.



edit - updated with examples



i assume you re-calculate these 2 values every time it is your turn?

edit
@onmach
which example shows inadequacy of your strategy? curious..

heh oops
yes
Daigomi
Profile Blog Joined May 2006
South Africa4316 Posts
March 03 2010 21:25 GMT
#7
+ Show Spoiler +
You add the value of all the odd numbered coins (coin #1, #3, etc) and all the even numbered coins (coin #2, #4, etc) together. If the odd numbered coins total the highest, you start on the left. If the even numbered coins have the highest total, you start on the right. After that you just pick on the same side as your opponent does every turn.
Moderator
Please log in or register to reply.
Live Events Refresh
Next event in 4h 33m
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
Nina 236
StarCraft: Brood War
Free 602
PianO 573
Leta 198
Dewaltoss 65
Shine 24
Noble 18
Bale 8
Dota 2
monkeys_forever713
League of Legends
JimRising 842
Counter-Strike
Stewie2K1026
Super Smash Bros
hungrybox780
Mew2King25
Westballz13
Heroes of the Storm
Khaldor88
Other Games
summit1g15698
shahzam776
ViBE218
NeuroSwarm64
SortOf12
Organizations
Other Games
gamesdonequick4626
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 14 non-featured ]
StarCraft 2
• Berry_CruncH372
• AfreecaTV YouTube
• intothetv
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
Dota 2
• lizZardDota284
League of Legends
• Rush2611
• HappyZerGling79
Upcoming Events
Wardi Open
4h 33m
Replay Cast
1d 3h
WardiTV European League
1d 9h
ShoWTimE vs sebesdes
Percival vs NightPhoenix
Shameless vs Nicoract
Krystianer vs Scarlett
ByuN vs uThermal
Harstem vs HeRoMaRinE
PiGosaur Monday
1d 17h
uThermal 2v2 Circuit
2 days
Replay Cast
2 days
The PondCast
3 days
Replay Cast
3 days
Epic.LAN
4 days
CranKy Ducklings
5 days
[ Show More ]
Epic.LAN
5 days
BSL20 Non-Korean Champi…
5 days
Bonyth vs Sziky
Dewalt vs Hawk
Hawk vs QiaoGege
Sziky vs Dewalt
Mihu vs Bonyth
Zhanhun vs QiaoGege
QiaoGege vs Fengzi
Sparkling Tuna Cup
6 days
Online Event
6 days
BSL20 Non-Korean Champi…
6 days
Bonyth vs Zhanhun
Dewalt vs Mihu
Hawk vs Sziky
Sziky vs QiaoGege
Mihu vs Hawk
Zhanhun vs Dewalt
Fengzi vs Bonyth
Liquipedia Results

Completed

2025 ACS Season 2: Qualifier
RSL Revival: Season 1
Murky Cup #2

Ongoing

JPL Season 2
BSL 2v2 Season 3
Copa Latinoamericana 4
Jiahua Invitational
BSL20 Non-Korean Championship
Championship of Russia 2025
BLAST.tv Austin Major 2025
ESL Impact League Season 7
IEM Dallas 2025
PGL Astana 2025
Asian Champions League '25
BLAST Rivals Spring 2025
MESA Nomadic Masters

Upcoming

CSL Xiamen Invitational
CSL Xiamen Invitational: ShowMatche
2025 ACS Season 2
CSLPRO Last Chance 2025
CSLPRO Chat StarLAN 3
BSL Season 21
K-Championship
RSL Revival: Season 2
SEL Season 2 Championship
uThermal 2v2 Main Event
FEL Cracov 2025
Esports World Cup 2025
Underdog Cup #2
StarSeries Fall 2025
FISSURE Playground #2
BLAST Open Fall 2025
BLAST Open Fall Qual
Esports World Cup 2025
BLAST Bounty Fall 2025
BLAST Bounty Fall Qual
IEM Cologne 2025
FISSURE Playground #1
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2025 TLnet. All Rights Reserved.