Of all the programming styles I have learned, dynamic programming is perhaps the most beautiful. It can take problems that, at first glance, look ugly and intractable, and solve the problem with clean, concise code. Where a simplistic algorithm might accomplish something by brute force, dynamic programming steps back, breaks the task into a smaller set of sequential parts, and then proceeds in the
![Dynamic Programming in Python: Bayesian Blocks](https://cdn-ak-scissors.b.st-hatena.com/image/square/e311c90d6d5033c1373c6537d2b8f398130ab224/height=288;version=1;width=512/http%3A%2F%2Fjakevdp.github.io%2Ffigures%2Fbayesblocks1.png)