Leetcode 6. ZigZag Conversion

题目描述:之字打印出字符串,并返回结果。 题目链接:Leetcode 6. ZigZag Conversion 思路就是初始化n行字符串,然后像搜索一样一个上一个下去搜索。 代码如下 class Solution(object): def convert(self, s, numRows): """ :type s: str :type numRows: int :rtyp
相关文章
相关标签/搜索