摘要:
Given an array of integers, every element appearsthreetimes except for one. Find that single one.Note:Your algorithm should have a linear runtime comp... 阅读全文
摘要:
Binary Tree Preorder TraversalTotal Accepted:4309Total Submissions:12898My SubmissionsGiven a binary tree, return thepreordertraversal of its nodes' v... 阅读全文
摘要:
Given two binary trees, write a function to check if they are equal or not.Two binary trees are considered equal if they are structurally identical an... 阅读全文
摘要:
Given a binary tree, find its maximum depth.The maximum depth is the number of nodes along the longest path from the root node down to the farthest le... 阅读全文
摘要:
Single NumberTotal Accepted:6830Total Submissions:14936My SubmissionsGiven an array of integers, every element appearstwiceexcept for one. Find that s... 阅读全文
摘要:
Merge Two Sorted ListsTotal Accepted:4404Total Submissions:13615My SubmissionsMerge two sorted linked lists and return it as a new list. The new list ... 阅读全文
摘要:
Given a linked list, remove thenthnode from the end of list and return its head.For example, Given linked list: 1->2->3->4->5, and n = 2. After re... 阅读全文
摘要:
Given an array and a value, remove all instances of that value in place and return the new length.The order of elements can be changed. It doesn't mat... 阅读全文
摘要:
Given a sorted linked list, delete all duplicates such that each element appear onlyonce.For example,Given1->1->2, return1->2.Given1->1->2->3->3, retu... 阅读全文
摘要:
You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single ... 阅读全文