In the Array class of the arrays.py file complete the following: Be…

Question In the Array class of the arrays.py file complete the following: Be… In the Array class of the arrays.py file complete the following:Be sure to reuse your solution from Programming Exercise 4.4 as your starter file for the arrays.py file. Define the __eq__ method.Python runs this method when an Array object appears as the left operand of the == operator.The method returns True if its argument is:Also an Array,Has the same logical size as the left operandThe pair of items at each logical position in the two arrays are equal.Otherwise, the method returns False.To test your program run the main() method below in the arrays.py file:def main(): “””Test code for modified Array class.””” a = Array(5) for item in range(4): a.insert(0, item) b = a c = Array(5) for item in range(4): c.insert(0, item) print(“True:”, a == b) print(“True:”, a is b) print(“True:”, a == c) print(“False:”, a is c) c.insert(10, 10) print(“False:”, a == c) c.pop(c.size() – 1) c[2] = 6 print(“False:”, a == c) d = [] print(“False:”, a == d)if __name__ == “__main__”: main()Your program’s output should look like the following:True: TrueTrue: TrueTrue: TrueFalse: FalseFalse: FalseFalse: FalseFalse: FalseGrading Write your Python code in the code editor. Use the Run button to execute and run the code. To review your progress, open up the “Tasks” panel on the left to view the curated list of tasks for the project.Once you are happy with the test results, click Submit and then the Confirm button to submit your project for grading. Computer Science Engineering & Technology Python Programming COP 3530 Share QuestionEmailCopy link Comments (0)