B 4.1.3 Worksheet 2 Python
Worksheet 2: SLL Insertion & Deletion (Python)Part 1: Code ImplementationContinue with your SinglyLinkedList and Node classes from Worksheet 1.Implement the insert_at_beginning(self, new_data) method in your SinglyLinkedList class.Implement the insert_after_node(self, prev_node_data, new_data) method.Implement the delete_node(self, key) method as shown in the lesson.In your if __name__ == "__main__": block:Create a...