Solution Review 1: Square Numbers and Return Their Sum
This lesson provides a solution review for the 'Square Numbers and Return Their Sum' challenge.
We'll cover the following...
Solution
Python 3.5
class Point:def __init__(self, x, y, z):self.x = xself.y = yself.z = zdef sqSum(self):a = self.x * self.xb = self.y * self.yc = self.z * self.zreturn(a + b + c)obj1 = Point(4, 5, 6)print(obj1.sqSum())
...