✅ Перевірена відповідь на це питання доступна нижче. Наші рішення, перевірені спільнотою, допомагають краще зрозуміти матеріал.
What is the output of the following code snippet?
class Node:
def __init__(self, data):
self.data = data
self.next = None
head = Node(10)
head.next = Node(20)
head.next.next = Node(30)
curr = head
while curr.next:
curr = curr.next
print(curr.data)