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
package main | |
import ( | |
"bytes" | |
"fmt" | |
"unsafe" | |
) | |
type Message struct { | |
buffer []byte |
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 json | |
import sqlite3 | |
import click | |
import re | |
import gzip | |
# Function to create the SQLite database and the necessary tables | |
def create_db(db_name: str) -> sqlite3.Connection: | |
conn = sqlite3.connect(db_name, autocommit=False, isolation_level="DEFERRED") | |
cursor = conn.cursor() |
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
package bench | |
import ( | |
"testing" | |
"time" | |
) | |
func BenchmarkMarshalBinary(b *testing.B) { | |
bs := make([]byte, 16*4) |
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
GO ?= go | |
export GITFLAGS='--filter=blob:none' | |
build: go.work | |
$(GO) build ./github.com/go-delve/delve/cmd/dlv | |
$(GO) build ./github.com/golangci/golangci-lint/cmd/golangci-lint | |
$(GO) build ./golang.org/x/tools/cmd/deadcode | |
$(GO) build ./golang.org/x/tools/gopls | |
$(GO) build ./honnef.co/go/tools/cmd/staticcheck |
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
echo "+/" $(sed -e 's/[^0-9]//g' -e 's/^\(.\)$/\1\1/' -e 's/^\(.\).*\(.\)$/\1\2/' ~/aoc-1.input) | ivy |
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
# Convert X hours Y minutes to Z minutes | |
op a mins b = (0 60 decode a b) | |
# data hours minutes hours minutes ... etc | |
x = 0 53 1 32 0 53 1 6 1 9 0 41 1 3 1 1 1 2 2 17 0 46 1 36 | |
# reduce | |
+/mins/((rho x)/2) 2 rho x | |
# hours |
This file has been truncated, but you can view the full file.
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
<?xml version="1.0"?> | |
<fix type="FIX" major="5" minor="0" servicepack="2"> | |
<header/> | |
<messages> | |
<message name="IOI" msgtype="6" msgcat="app"> | |
<component name="ApplicationSequenceControl" required="N"/> | |
<field name="IOIID" required="Y"/> | |
<field name="IOITransType" required="Y"/> | |
<field name="IOIRefID" required="N"/> |
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
<div>pwet</div> |
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
#!/usr/bin/env python3 | |
# -*- coding: utf-8 -*- | |
# This file is part based on github.com/maaaaz/fgpoliciestocsv | |
# | |
# Copyright (C) 2021, Sylvain Rabot <sylvain at abstraction .fr> | |
# Copyright (C) 2014, 2020, Thomas Debize <tdebize at mail.com> | |
# All rights reserved. | |
# | |
# This script is a free software: you can redistribute it and/or modify |
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
#!/usr/bin/env python3 | |
# -*- coding: utf-8 -*- | |
# This file is based on github.com/maaaaz/fgpoliciestocsv | |
# | |
# Copyright (C) 2021, Sylvain Rabot <sylvain at abstraction .fr> | |
# Copyright (C) 2014, 2020, Thomas Debize <tdebize at mail.com> | |
# All rights reserved. | |
# | |
# This script is a free software: you can redistribute it and/or modify |
NewerOlder