摘要:
Divide two integers without using multiplication, division and mod operator.If it is overflow, return MAX_INTpublic class Solution { //本题很多细节需要考虑: ... 阅读全文
摘要:
Implement strStr().Returns the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack.public class Solution { ... 阅读全文
摘要:
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 array, remove the duplicates in place such that each element appear onlyonceand return the new length.Do not allocate extra space for a... 阅读全文
摘要:
Given a linked list, reverse the nodes of a linked listkat a time and return its modified list.If the number of nodes is not a multiple ofkthen left-o... 阅读全文
摘要:
Given a linked list, swap every two adjacent nodes and return its head.For example,Given1->2->3->4, you should return the list as2->1->4->3.Your algor... 阅读全文