|
-
July 27th, 2015, 07:26 AM
#3
Re: Algorithm for simple board game
this is a simple math problem.
all coins into the 'right' squares gives a total score of N*A+M*B
as many coins as possible into the 'wrong' squares is 2*min(N,M)*C + (N-min(N,M))*A + (M-min(N,M))*B
follow whichever of the above 2 possibilities gives the highest value
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|