Skip to content

Instantly share code, notes, and snippets.

View countMonteCristo's full-sized avatar

Artem Shapovalov countMonteCristo

View GitHub Profile
'''NyashStatistics
запрос для авторизации:
https://oauth.vk.com/authorize?client_id=APP_ID&scope=messages,photos&
redirect_uri=https://oauth.vk.com/blank.html&display=page&v=5.27&
response_type=token
ответ после разрешения прав для приложения:
https://oauth.vk.com/blank.html#access_token=TOKEN&expires_in=86400&user_id=UID
TOKEN из ответа берём access_token и засовываем его в ACCESS_TOKEN
def f(l=[]):
l.append(len(l)+1)
print(l)
from bs4 import BeautifulSoup as bs
import urllib.request as req
''' get statistics'''
wall_of_shame = req.urlopen('http://python3wos.appspot.com/').read().decode()
soup = bs(wall_of_shame, 'html.parser')
rows = soup.find_all('tr')[1:]
d = {'py3False':[], 'py3True':[]}