79657554

Date: 2025-06-08 06:01:11
Score: 1
Natty:
Report link

well, they have a different value because:

In Solution1, self.ans is shared and persistent across method calls.

In Solution2, unless special handling is used, the modification of ans inside some_other_function does not affect the outer ans.

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: the optimist