mersenneforum.org

mersenneforum.org (https://www.mersenneforum.org/index.php)
-   Puzzles (https://www.mersenneforum.org/forumdisplay.php?f=18)
-   -   August 2014 (https://www.mersenneforum.org/showthread.php?t=19583)

Xyzzy 2014-08-09 16:02

August 2014
 
[url]http://domino.research.ibm.com/Comm/wwwr_ponder.nsf/challenges/August2014.html[/url]

axn 2014-08-09 16:52

[CODE][SPOILER]cost=vector(100); choice=vector(100);
cost[1]=0; choice[1]=1;
for(i=2,100, mcost=10000; mchoice=0; for(ch=1,i-1, ncost=(ch/i)*(1+cost[ch])+((i-ch)/i)*(10+cost[i-ch]); if(ncost < mcost, mcost=ncost; mchoice=ch)); cost[i]=mcost; choice[i]=mchoice)[/SPOILER][/CODE]

Xyzzy 2014-11-02 19:04

[url]http://domino.research.ibm.com/Comm/wwwr_ponder.nsf/solutions/August2014.html[/url]


All times are UTC. The time now is 19:57.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2022, Jelsoft Enterprises Ltd.