A helper function to find the length of linked list
def getSize ( a ) : NEW_LINE INDENT sz = 0 ; NEW_LINE while ( a != None ) : NEW_LINE INDENT a = a . next ; NEW_LINE sz += 1 NEW_LINE DEDENT return sz ; NEW_LINE DEDENT