上一页 1 ··· 22 23 24 25 26 27 28 29 30 ··· 37 下一页
摘要: Suppose an array sorted in ascending order is rotated at some pivot unknown to you beforehand. (i.e., [0,1,2,4,5,6,7] might become [4,5,6,7,0,1,2]). F 阅读全文
posted @ 2018-12-19 12:40 fatttcat 阅读(89) 评论(0) 推荐(0) 编辑
摘要: Implement atoi which converts a string to an integer. The function first discards as many whitespace characters as necessary until the first non-white 阅读全文
posted @ 2018-12-19 12:09 fatttcat 阅读(127) 评论(0) 推荐(0) 编辑
摘要: Given an array w of positive integers, where w[i] describes the weight of index i, write a function pickIndex which randomly picks an index in proport 阅读全文
posted @ 2018-12-19 10:07 fatttcat 阅读(124) 评论(0) 推荐(0) 编辑
摘要: Given two non-negative integers num1 and num2 represented as string, return the sum of num1 and num2. Note: The length of both num1 and num2 is < 5100 阅读全文
posted @ 2018-12-19 05:12 fatttcat 阅读(88) 评论(0) 推荐(0) 编辑
摘要: The API: int read4(char *buf) reads 4 characters at a time from a file. The return value is the actual number of characters read. For example, it retu 阅读全文
posted @ 2018-12-19 04:43 fatttcat 阅读(133) 评论(0) 推荐(0) 编辑
摘要: The API: int read4(char *buf) reads 4 characters at a time from a file. The return value is the actual number of characters read. For example, it retu 阅读全文
posted @ 2018-12-19 04:09 fatttcat 阅读(156) 评论(0) 推荐(0) 编辑
摘要: Given a linked list, remove the n-th node from the end of list and return its head. Example: Given linked list: 1->2->3->4->5, and n = 2. After removi 阅读全文
posted @ 2018-12-18 10:25 fatttcat 阅读(92) 评论(0) 推荐(0) 编辑
摘要: Given two integers dividend and divisor, divide two integers without using multiplication, division and mod operator. Return the quotient after dividi 阅读全文
posted @ 2018-12-18 09:30 fatttcat 阅读(112) 评论(0) 推荐(0) 编辑
摘要: Given a non-empty string s, you may delete at most one character. Judge whether you can make it a palindrome. Example 1: Input: "aba" Output: True Exa 阅读全文
posted @ 2018-12-18 07:54 fatttcat 阅读(88) 评论(0) 推荐(0) 编辑
摘要: Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases. Note: For the purpose of this problem, w 阅读全文
posted @ 2018-12-18 07:23 fatttcat 阅读(91) 评论(0) 推荐(0) 编辑
上一页 1 ··· 22 23 24 25 26 27 28 29 30 ··· 37 下一页