ZigzagConvert】的更多相关文章

public class ZigzagConvert { public static String convert(String s, int nRows) { int len = s.length(); if (len == 0 || nRows < 2) return s; String ret = "";//赋值可以定义ret=null;但是拼接字符串的时候不行,只能定义"" int lag = 2*nRows - 2; //循环周期 for (int…
LeetCode Algorithm 原文出处:[LeetCode] 算法参考:[陈皓 coolshell] 1. Two Sum 3. Longest Substring Without Repeating Characters 5. Longest Palindromic Substring 6. ZigZag Conversion 7. Reverse Integer 8. String to Integer (atoi) 9. Palindrome Number 12. Integer…