I hereby claim:
- I am artemgr on github.
- I am artemciy (https://keybase.io/artemciy) on keybase.
- I have a public key ASCUwRz1jGzzJ5ZZsUS6-rRSQSqBmYnZ77If1bdOyBWnfAo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
#If WinActive("Druidstone") | |
q:: | |
MouseGetPos, mouseStartX, mouseStartY | |
if WinExist("Cheat Happens Trainer") { | |
WinActivate | |
WinMove, 600, 111 | |
MouseMove, 210, 180, 5 | |
MouseClick, Left | |
MouseMove, 900, 320, 5 |
// https://stackoverflow.com/questions/33424185/why-are-incorrect-type-assignments-allowed-in-dart | |
void main() { | |
Map<String, dynamic> map = { | |
'str': 'test', | |
'integer': 5, | |
'decimal': 1.5, | |
'list': [1,2,3] | |
}; |
// https://stackoverflow.com/questions/33424185/why-are-incorrect-type-assignments-allowed-in-dart | |
void main() { | |
String str = "test"; | |
int integer = 5; | |
double decimal = 1.5; | |
List list = [1,2,3]; | |
String s = decimal; print(s); // 1.5 | |
int i = str; print(i); // test |
val pattern = java.util.regex.Pattern.compile ("""(?xs) ("(.*?)"|) ; ("(.*?)"|) (?: \r?\n | \z ) """) | |
val matcher = pattern.matcher (input) | |
while (matcher.find) { | |
val col1 = matcher.group (2) | |
val col2 = matcher.group (4) | |
// ... | |
} |
Password security relies to a large degree on the time limits imposed upon password verification.
That is, if I can verify three passwords per minute then guessing an alphanumeric password of eight characters
might take approximately Math.pow (36, 8) / 2 / (86400 / 20) / 365
= 2236 years,
but if I can verify three million passwords per second
then guessing the same password might take Math.pow (36, 8) / 2 / (86400 * 3000000)
= 5 days.
If we limit a PIN to be verified no more than three times per ten minutes
// Asynchronous PostgreSQL INSERT. | |
glim::NsecTimer timer; | |
std::unique_ptr<PGconn, void(*)(PGconn*)> pg (PQconnectStart (pcs.c_str()), PQfinish); | |
if (pg.get() == nullptr || PQstatus (pg.get()) == CONNECTION_BAD) GTHROW ("!PQconnectStart"); | |
int sock = PQsocket (pg.get()); | |
auto evBase = EvServ::instance()->evbase(); | |
event_callback_fn cbcoroInvokeFromCallback = [](evutil_socket_t, short, void* cbcoro) {((CBCoro*) cbcoro)->invokeFromCallback();}; | |
std::unique_ptr<struct event, void(*)(struct event*)> evRead (event_new (evBase.get(), sock, EV_READ, cbcoroInvokeFromCallback, cbcoro), event_free); |
// Cygwin: cd /tmp; g++ -O3 -fno-inline-functions -Wall -std=c++11 /c/spool/Promo/personal/artemgr/games/eador.cc -o eador -lz | |
// MinGW: g++ -static -O3 -fno-inline-functions -Wall -std=c++11 -I/boost/include/boost-1_53 eador.cc -o eador.exe -lz | |
#include <stdlib.h> | |
#include <stdio.h> | |
#include <sys/stat.h> | |
#include <unistd.h> | |
#include <ctype.h> | |
#include <errno.h> | |
#ifdef __MINGW32__ |
#include <lzma.h> // http://tukaani.org/xz/ | |
#include <memory> // unique_ptr | |
#include <stdexcept> // runtime_error | |
#include <glim/gstring.hpp> // Here glim::gstring can be replaced with std::string. | |
using glim::gstring; | |
static void xzCompress (const gstring& from, gstring& to) { | |
// See also LZMA example at: http://git.tukaani.org/?p=xz.git;a=blob;f=doc/examples/01_compress_easy.c | |
lzma_stream strm = LZMA_STREAM_INIT; | |
std::unique_ptr<lzma_stream, void(*)(lzma_stream*)> freeStream (&strm, lzma_end); |
[package] | |
name = "hex" | |
version = "0.1.0" | |
[dependencies] | |
fomat-macros = "*" |