摘要: 注意审题,题目中是listnode链表,不是list 阅读全文
posted @ 2017-07-13 15:54 hafgyyb 阅读(91) 评论(0) 推荐(0)
摘要: Given a digit string, return all possible letter combinations that the number could represent. A mapping of digit to letters (just like on the telepho 阅读全文
posted @ 2017-07-03 23:22 hafgyyb 阅读(97) 评论(0) 推荐(0)
摘要: Given an input string, reverse the string word by word. For example,Given s = "the sky is blue",return "blue is sky the". Update (2015-02-12):For C pr 阅读全文
posted @ 2017-06-29 10:42 hafgyyb 阅读(134) 评论(0) 推荐(0)
摘要: You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order and each of their nodes contai 阅读全文
posted @ 2017-06-28 18:41 hafgyyb 阅读(122) 评论(0) 推荐(0)
摘要: Given an array of integers, return indices of the two numbers such that they add up to a specific target. You may assume that each input would have ex 阅读全文
posted @ 2017-06-28 16:11 hafgyyb 阅读(117) 评论(0) 推荐(0)
摘要: Given n non-negative integers a1, a2, ..., an, where each represents a point at coordinate (i, ai). n vertical lines are drawn such that the two endpo 阅读全文
posted @ 2017-05-22 21:15 hafgyyb 阅读(93) 评论(0) 推荐(0)
摘要: 题目描述 给定两个字符串,请编写程序,确定其中一个字符串的字符重新排列后,能否变成另一个字符串。这里规定大小写为不同字符,且考虑字符串重点空格。 给定一个string stringA和一个string stringB,请返回一个bool,代表两串是否重新排列后可相同。保证两串的长度都小于等于5000 阅读全文
posted @ 2017-03-29 21:28 hafgyyb 阅读(154) 评论(0) 推荐(0)
摘要: 请实现一个算法,在不使用额外数据结构和储存空间的情况下,翻转一个给定的字符串(可以使用单个过程变量)。 给定一个string iniString,请返回一个string,为翻转后的字符串。保证字符串的长度小于等于5000。 测试样例: s.append(s.charAt(i));???这是什么,思维 阅读全文
posted @ 2017-03-29 21:16 hafgyyb 阅读(165) 评论(0) 推荐(0)