2015年10月20日

[leetcode]Integer to Roman

摘要: class Solution {public: string intToRoman(int num) { string a[10] = {"","I", "II", "III", "IV", "V", "VI", "VII", "VIII", "IX"}; stri... 阅读全文

posted @ 2015-10-20 22:18 Mereyct 阅读(219) 评论(0) 推荐(0) 编辑

[leetcode]String to Integer (atoi)

摘要: class Solution {public: int myAtoi(string str) { long long sum = 0; int temp1 = 1; int max1 = 0x7fffffff; int min1 = ... 阅读全文

posted @ 2015-10-20 20:29 Mereyct 阅读(212) 评论(0) 推荐(0) 编辑

[leetcode]ZigZag Conversion

摘要: 1 class Solution { 2 public: 3 string convert(string s, int numRows) { 4 if(numRows <= 1 || s.size() == 0) 5 return s; 6 ... 阅读全文

posted @ 2015-10-20 13:40 Mereyct 阅读(139) 评论(0) 推荐(0) 编辑

导航