[Solved] Why does this result in a can’t assign to operator error?


I don’t believe that you can reverse that. Instead, do

QP = point * hours

That way, you instantiate the new variable, and set it to the product of the points and the hours.

Some other issues: your point variable isn’t defined either. You need

self.point = point

in order to have the variable as an actual variable. Also, it might cause some confusion between the point function and the point variable, because of the two being the same name. One or the other, I’d name one as points.

2

solved Why does this result in a can’t assign to operator error?