All Questions
2 questions
-3
votes
3
answers
46
views
What is the difference when assigning an object like a LinkedList to a variable versus an array?
I was working on this problem from HackerRank trying to insert an element at the tail of a linked list and I have to return the head of the node.
def insertNodeAtTail(head, data):
if head is None:...
1
vote
2
answers
34
views
Does python multivariable assignment order mattering?
I am working on leetcode problem 206 and have come up with :
class Solution(object):
def reverseList(self, head):
"""
:type head: ListNode
:rtype: ListNode
...