Ad
  • Custom User Avatar

    Python: Issues with (Possibly) test cases? This is odd. My code runs fine on my IDE. My equals function returns true or false and my athrmeitc functions reference my equals function and raise exception if the two vectors are different lengths. When tested "a.add(b).equals()' gives AttributeError: 'list' object has no attribute 'equals' becuase the response from my add function is another list, as the sum of the two vectors. are we meant to instantiate another Vector class as the response and check if it is equal to one or both input vector objects?

    Can someone explain how to make the equals function pass through the test cases? or restate what is expected here?

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution