Skip to content

Instantly share code, notes, and snippets.

View zulman's full-sized avatar
:octocat:
undefined string

Oleg Chumakov zulman

:octocat:
undefined string
View GitHub Profile
@zulman
zulman / gist:4072237
Created November 14, 2012 13:57
DL Config
WorkDir = C:\Users\oleg.chumakov\Desktop\AllClients-Starforce-ap9.5.0-tr-TR-56239.9-56294.18756.11-15-12\Castle
ExeName = Castle.exe
AuthServer = http://pw.zzima.com:99/
ProtocolVersion = 0.12.32
Arguments =
[fb]
AppId = 137661392984435
AppSecret = 040c28ebcee0cab600368fd5fbb2bddf
@zulman
zulman / 600213199.txt
Created February 6, 2013 07:39
Test data for counting inversions algorithm. Answer is 600213199.
54044
14108
79294
29649
25260
60660
2995
53777
49689
9083
@zulman
zulman / gist:4958850
Created February 15, 2013 06:32
qsort comparisons test data
| | # of Comparisons with |
| Array | first | last | median |
| | pivot |
|-------------+-------+------+--------|
| 1 | 0 | 0 | 0 |
| 1 2 | 1 | 1 | 1 |
| 1 2 3 | 3 | 3 | 2 |
| 1 2 3 4 | 6 | 6 | 4 |
| 9 6 3 7 2 4 | 11 | 9 | 8 |
| 9 6 3 7 4 2 | 13 | 13 | 9 |
<?xml version="1.0" encoding="UTF-8" ?>
<widget xmlns = "http://www.w3.org/ns/widgets"
xmlns:gap = "http://phonegap.com/ns/1.0"
id = "com.the21.green"
versionCode="10"
version = "1.0.0">
<!-- versionCode is optional and Android only -->
<name>com.the21.green</name>
/*Функция возвращет объект Date. В нем записано сколько времени до полуночи в часовом поясе пользователя*/
function datetimeUntilMidnight() {
var midnight = new Date();
midnight.setHours( 24 );
midnight.setMinutes( 0 );
midnight.setSeconds( 0 );
midnight.setMilliseconds( 0 );
return ( midnight - new Date() );
}
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import traceback
import threading
from telegram.ext import Updater, CommandHandler
def start(bot, update):
s = ""
for line in traceback.format_stack():
s = s + line.strip() +"\n"