This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Russian adoption | |
Did he pay Stormy Daniels or not? | |
My tax returns are under audit | |
Obama tapped my wires | |
Melania Trump tweet of 5/30 | |
Misspoke my only sentence of criticism to Putin | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ip.addr('add', index=idx, | |
address='10.1.1.2', | |
mask=24, | |
local='10.1.1.1') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import operator as op | |
def ncr(n, r): | |
r = min(r, n-r) | |
if r == 0: return 1 | |
numer = reduce(op.mul, xrange(n, n-r, -1)) | |
denom = reduce(op.mul, xrange(1, r+1)) | |
return numer//denom |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# set window size appropriately | |
resize() { | |
local IFS='[;' escape geometry x y | |
echo -en '\e7\e[r\e[999;999H\e[6n\e8' | |
read -sd R escape geometry | |
x=${geometry##*;} y=${geometry%%;*} | |
stty cols ${x} rows ${y} | |
} | |
case "$-" in |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
224 sudo yum install python-urllib3 | |
225 sudo pip install docker-py | |
232 sudo yum install -y python-six | |
233 sudo pip install --upgrade six | |
234 python |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from PyQt4 import QtCore | |
import time | |
import sys | |
from subprocess import call, Popen, PIPE, STDOUT | |
class SomeObject(QtCore.QObject): | |
finished = QtCore.pyqtSignal() | |
progress = QtCore.pyqtSignal(['QString']) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
app = QtGui.QApplication(sys.argv) | |
db = QSqlDatabase.addDatabase("QSQLITE") | |
db.setDatabaseName("stest.sqlite") | |
model = QSqlTableModel(app); | |
model.setTable("test") | |
model.setFilter("key like '%1'") | |
Dialog = QtGui.QDialog() | |
ui = Ui_Dialog() | |
ui.setupUi(Dialog) | |
ui.comboBox.setModel(model) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
You can't speak matter of factually about things you can't measure. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$TTL 604800 | |
@ IN SOA localhost. root.localhost. ( | |
1 ; Serial | |
604800 ; Refresh | |
86400 ; Retry | |
2419200 ; Expire | |
604800 ) ; Negative Cache TTL | |
; | |
@ IN NS dns.generic.com. | |
250 IN PTR dns.generic.com. |