Xtreme Maya Diet

It works for the given sample inputs and uses dynamic programming, which I started to find much easier for these kind of problems. The code is up to no standard and I didn’t expect it to be, but its readable and has proper indentation(which is all I care). So here’s the code.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s