Hi all, felt really happy to be the first one to submit a solution to this spoj challenge. This is a challenge problem so the shorter the code, the more points. Well i did remain the winner till a couple of hours till my code length was beaten by numerix, who is one of the best python coders around.
Hoping to improve my code and learn more python.