This file contains 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 ipaddress | |
import os | |
import socket | |
import subprocess | |
def parse_ip_port(c): | |
ip_h, port_h = c.split(":") | |
return str(ipaddress.IPv4Address(socket.htonl(int(ip_h, 16)))), int(port_h, 16) |
This file contains 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
const uint32_t CONNECTIONLESS_HEADER = 0xFFFFFFFF; | |
const uint8_t A2S_GETCHALLENGE = 'q'; | |
const uint8_t S2C_CHALLENGE = 'A'; | |
const uint8_t C2S_CONNECT = 'k'; | |
const uint8_t S2C_CONNECTION = 'B'; | |
const uint32_t PROTOCOL_HASHEDCDKEY = 0x02; | |
const uint32_t PROTOCOL_STEAM = 0x03; |
This file contains 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
#!/usr/bin/env python3 | |
# License: GPLv3 | |
import re | |
import json | |
import shutil | |
import subprocess | |
import sys | |
import urllib.parse |
This file contains 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 struct | |
import collections | |
import PIL.Image | |
# Attempt to extract images from Macromedia Director dxr/dir files | |
PATH = "ber.dxr" | |
CHUNK_FMT = ">4sL" | |
CHUNK_SIZE = struct.calcsize(CHUNK_FMT) |
This file contains 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
# Compile: nim c --mm:arc --threads:on --threadanalysis:off threadbugs.nim | |
import threadpool | |
type | |
DataItem = object | |
value: int | |
ContainerItem = object | |
data: ref DataItem |
This file contains 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 dynlib | |
type | |
PixelRgba = object | |
r, g, b, a: uint8 | |
Image = ref object of RootObj | |
width: int | |
height: int |
This file contains 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 random | |
type | |
TileType = enum | |
wall, path | |
Direction = enum | |
north, east, south, west | |
Playfield = object |
This file contains 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 sqlite3 | |
import datetime | |
import json | |
import csv | |
import sys | |
INDEX_PATH = "gogdb_index.sqlite3" | |
START_DATE = "2021-01-12" | |
conn = sqlite3.connect(INDEX_PATH) |
This file contains 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
# Compile: gcc aoc_day1.s -nostdlib -fPIC -o aoc_day1 | |
.intel_syntax noprefix | |
.data | |
.section .rodata | |
filename: | |
.string "input_1.txt" | |
errormsg_open: | |
.string "Failed to open file\n" | |
.set errormsg_open_len, . - errormsg_open - 1 |
This file contains 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
Pernauer Chemiewerke products and their detergemtinfo.at number. | |
http://www.detergentinfo.at/PR<num>.php | |
51 Clever Glasreiniger 1000ml | |
102 Clever Weichspüler Wildrose 1,5l | |
103 Clever Weichspüler Wasserlilie 1,5l | |
125 Clever Allzweckreiniger 1000ml | |
164 bi good Allzweckreiniger 1000ml | |
165 bi good Badreiniger 500mL | |
166 bi good Glasreiniger 500mL |
NewerOlder