Text Wrap

  • + 1 comment

    Going through Text Wrap lib, it's preety easy problem need one line of command to add,

    Find it below Cheers!!!!

    import textwrap

    def wrap(string, max_width): return textwrap.fill(string, max_width)

    if name == 'main': string, max_width = input(), int(input()) result = wrap(string, max_width) print(result)

    • + 0 comments

      cool