I hereby claim:
- I am ztane on github.
- I am anttihaapala (https://keybase.io/anttihaapala) on keybase.
- I have a public key whose fingerprint is B811 2F0F ACC5 6F06 B79C 4E4D 69C6 71AF 0959 C672
To claim this, I am signing this object:
#!/usr/bin/python3 | |
import sys | |
def read_block(): | |
block_id = f.read(16) | |
version = f.read(4) | |
size = f.read(4) | |
contents = f.read(int.from_bytes(size, "little")) | |
return block_id, version, size, contents |
import re | |
import itertools | |
def ugettext(s): | |
c = itertools.cycle('yada') | |
def replace(m): | |
char = m.group(0) | |
replacement = next(c) | |
if char.isupper(): |
#include <stdio.h> | |
#define BUGGY | |
void funcA(int s, int g) | |
{ | |
int i, j = 0, k; | |
int grp[4] = {-1, -1}; | |
for (i = 0, k = 0; i < 1; ++i) { |
int foo(int a, int b) { | |
if ((a-b)==0) { | |
return 1; | |
} | |
return 0; | |
} | |
int bar(int a, int b) { | |
if (a==b) { | |
return 1; |
from collections import defaultdict | |
import time | |
i = 100 | |
for _ in range(3): | |
list_of_dictionaries = [{1: 1} for i in range(i)] | |
list_of_dictionaries.append(dict.fromkeys(range(i))) | |
n = sum(map(len, list_of_dictionaries)) |
(function ($) { | |
function doSerializeArrayItems($current, target) { | |
$current.children().each(function (i, e) { | |
var $e = $(e), | |
tmp; | |
if (e.hasAttribute('data-form-item')) { | |
var o = {}; | |
target.push(o); | |
doSerialize($e, o); | |
} |
# advent of code helpers for Python 3 | |
def input_file(filename='input'): | |
""" | |
Read the input from current working directory, | |
return as a string stripped | |
""" | |
with open(input) as f: | |
return f.read().strip() |
I hereby claim:
To claim this, I am signing this object:
%{ | |
#include <stdio.h> | |
int line_num = 1; | |
%} | |
%% | |
"(" { printf("a opening parenthesis\n"); } | |
")" { printf("a closing parenthesis\n"); } | |
[0-9]+ { printf("a number: %s\n", yytext); } |
import warnings | |
import inspect | |
NONE = object() | |
class TypingWarning(Warning): | |
pass | |