Second constructed linked list is : 35 . 1 . 12 . 1 . 10 . 34
second = push ( second , 35 ) NEW_LINE second = push ( second , 1 ) NEW_LINE second = push ( second , 12 ) NEW_LINE second = push ( second , 1 ) NEW_LINE second = push ( second , 10 ) NEW_LINE second = push ( second , 34 ) NEW_LINE if ( isPermutation ( first , second ) ) : NEW_LINE INDENT print ( " Yes " ) NEW_LINE DEDENT else : NEW_LINE INDENT print ( " No " ) NEW_LINE DEDENT