摘要: 题目描述 利用字符重复出现的次数,编写一个方法,实现基本的字符串压缩功能。比如,字符串“aabcccccaaa”经压缩会变成“a2b1c5a3”。若压缩后的字符串没有变短,则返回原先的字符串。 给定一个string iniString为待压缩的串(长度小于等于3000),保证串内字符均由大小写英文字 阅读全文
posted @ 2016-02-01 15:27 梦幻之海 阅读(1880) 评论(0) 推荐(0) 编辑
摘要: Given an array of integers, find two numbers such that they add up to a specific target number. The function twoSum should return indices of the two n 阅读全文
posted @ 2016-02-01 13:39 梦幻之海 阅读(136) 评论(0) 推荐(0) 编辑