a thoughtful web.
Good ideas and conversation. No ads, no tracking.   Login or Take a Tour!
comment
bhrgunatha  ·  3145 days ago  ·  link  ·    ·  parent  ·  post: A nice problem from SICP

I'm impressed you managed a solution for 3 coins.

> count_change does get quite slow for n >> 10^6 (that's $10,000.00)

From a pure math angle, both memo & dynamic programming versions are linear in time and space. As you said though, those numbers are growing exponentially meaning the space will grow exponentially too.