Euler project solution written in python language