Skip to content

Instantly share code, notes, and snippets.

View promsoft's full-sized avatar

Dmitry Kolodezev promsoft

View GitHub Profile
a = []
padd = [0]*9
source = list(range(7))
def logic(a):
a = a + padd
if a[0] + a[1] + a[2] > 13:
return False
if a[3] + a[4] + a[5] > 13:
return False
if a[6] + a[7] + a[8] > 13:
@promsoft
promsoft / html2txt.py
Last active February 18, 2017 18:24
Get text from html
import requests
html = requests.get('https://promsoft.ru').text
from bs4 import BeautifulSoup
from bs4.element import NavigableString
def html2txt(html):
soup = BeautifulSoup(html, 'lxml')
for elem in soup.findAll(['script', 'style']):
https://oauth.vk.com/authorize?client_id=XXXXXXXXXXXXXXX&scope=messages&response_type=token
https://oauth.vk.com/authorize?client_id=XXXXXXXXXXX&scope=messages,offline&response_type=token
https://api.vk.com/method/messages.get?access_token=TOKEN&count=200
# https://api.vk.com/method/messages.getHistory?access_token=TOKEN&user_id=USERID&count=200
@promsoft
promsoft / Untitled.ipynb
Created December 5, 2017 07:27
clipboaard
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@promsoft
promsoft / slides.ipynb
Last active August 24, 2022 21:06
Мастеркласс по MongoDB
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@promsoft
promsoft / review.ipynb
Created February 13, 2018 08:58
current/dk_alice/eda/review.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@promsoft
promsoft / memory.ipynb
Created June 28, 2018 07:51
Jupyter Memory tricks
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.