

def getDecimalValue(head):
    if head is None: 
        return 0

    temp=''

    while (head):
        temp = temp + str(head.val)
        head = head.next

    return (int(temp,2))

254d87adbf3616a5f92f69da945ff4e1e881806a
<mask token>

def getDecimalValue(head):
    if head is None:
        return 0
    temp = ''
    while head:
        temp = temp + str(head.val)
        head = head.next
    return int(temp, 2)



def getDecimalValue(head):
    if head is None: 
        return 0

    temp=''

    while (head):
        temp = temp + str(head.val)
        head = head.next

    return (int(temp,2))
