Saturday, February 26, 2011

Project Euler Level 1

I have been interested in puzzles since I was little. After learning programming I would search out puzzles that could be solved by coding. Few years back while I was pursuing my B.Sc. I encountered Project Euler:
Project Euler is a series of challenging mathematical/computer programming problems that will require more than just mathematical insights to solve. Although mathematics will help you arrive at elegant and efficient methods, the use of a computer and programming skills will be required to solve most problems.
I got hooked on solving these problems. Sometime along the line I gave up due to exams or some other commitments. Now that I have started learning Python, I was again hunting for puzzles that I could solve with my Python coding skills. This is how I encountered Project Euler for the second time. I managed to pick up from where I had left duing my B.Sc. Today I managed to reach level 1. While its not much of an achievement considering a lot of people before me have successfully done it, but nonetheless it feels great.


I tried to solve most of the problems in Python. But sometimes ended up using good old C. Sometimes I would just use Java or C++ for the rich template libraries that these languages have. Some of the solutions lent themselves to Matlab and (surprise, surprise) Calc (open office version of MS Excel). Only 2 could be solved by analytical reasoning alone.

Lets see how many I can solve. But its great fun to develop a solution and in the process explore some of the unknown language features and libraries.


No comments:

Post a Comment

I'd love to hear from you !