Skip to content

Instantly share code, notes, and snippets.

@dndx
dndx / xiami_decode.py
Created April 29, 2012 14:42
Xiami URL Decoder
import urllib2
def xiami_decode(s):
s = s.strip()
if not s:
return False
result = []
line = int(s[0])
rows = len(s[1:]) / line
extra = len(s[1:]) % line