Skip to content

Instantly share code, notes, and snippets.

View xhat's full-sized avatar
🤒
Out sick

xhat xhat

🤒
Out sick
View GitHub Profile
#!/usr/bin/env python
#-*- coding: utf-8 -*-
import sys
import logging
import datetime
import requests
import BeautifulSoup
from requests.adapters import HTTPAdapter
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