Run-length decompression

前端 未结 6 1537
天涯浪人
天涯浪人 2021-01-26 17:25

CS student here. I want to write a program that will decompress a string that has been encoded according to a modified form of run-length encoding (which I\'ve already written c

6条回答
  •  执笔经年
    2021-01-26 18:12

    I think you can divide chars in numeric and not numeric symbols.

    When you find a numeric one (>0 and <9) you look to the next and choose to enlarge you number (current *10 + new) or to expand your string

提交回复
热议问题