Solving A System Of Equations In Python