---
title: "Discussion on \"Zigzag conversion\" | Hashnode"
description: "Discussion on \"Zigzag conversion\". Here is the solution of python:\nlass Solution:\n    def convert(self, s: str, numRows: int) -> str:\n\n        if numRows == 1 or numRows >= len(s):\n            return s\n\n        # Create an empty list to hold characters in each row\n        rows = [''] ..."
url: "https://hashnode.com/posts/zigzag-conversion/6447f8171d736eb3207e5ced"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Zigzag conversion](https://ubuntumeta.hashnode.dev/zigzag-conversion?utm_source=hashnode&utm_medium=feed)

Here is the solution of python: lass Solution: def convert(self, s: str, numRows: int) -> str: if numRows == 1 or numRows >= len(s): return s # Create an empty list to hold characters in each row rows = \[''\] ...

Apr 25, 2023 · 1 min read · ubuntumeta.hashnode.dev  
Read the article

-   [#python](https://hashnode.com/tag/python)
-   [#zigzag](https://hashnode.com/tag/zigzag)

## Written by

[Ubuntu Tang](https://hashnode.com/@UbuntuMeta)

@UbuntuMeta · Califoria, US

  
[View profile](https://hashnode.com/@UbuntuMeta)

Dev

A developer for fullstack.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
