Method Inside Class Python Definition Function Algebra Problems