Skip to content

Instantly share code, notes, and snippets.

View visortelle's full-sized avatar
🎯

Kiryl Valkovich visortelle

🎯
View GitHub Profile
lookup 0 1 4 16 64 256 1,024 4,096 16,192 65,536 262,144 1,048,576
Set 0 ± 0% 12 ± 0% 57 ± 0% 307 ± 0% 1,410 ± 1.1% 6,200 ± 1.8% 30,500 ± 1.2% 143,000 ± 1.4% 820,000 ± 1.4% 4,510,000 ± 2.1% 42,000,000 ± 6.3%
j.ArrayList 0 ± 0% 3 ± 0% 4 ± 0% 4 ± 0% 4 ± 0% 4 ± 0% 4 ± 25.0% 3 ± 166.7% 10 ± 261.5% 90 ± 72.2% 1,000 ± 232.0% -11,000 ± 52.6%
m.Map 0 ± 0% 5 ± 0% 20 ± 0% 82 ± 1.2% 337 ± 2.1% 1,460
@suhr
suhr / proofs.md
Last active December 8, 2022 13:05

Упражнения по формальным доказательствам

Нет времени объяснять, переходим сразу к делу.

Инструменты

Доказывать теоремы мы будем, используя интерактивные пруверы Isabelle или Lean 3. Примеры приводятся для каждого прувера, для решения задач же можно использовать любой из них.

@Sunlighter
Sunlighter / README.md
Last active November 12, 2022 11:21
Installing .NET 5 in Amazon Linux 2 for ARM

Installing .NET 5 in Amazon Linux 2 for ARM64

This is a way to install .NET 5 in your home directory without modifying the system.

At the time of this writing, Amazon Linux 2 for ARM64 almost works already, but there is a problem with the ICU library. I will show this problem and how to fix it.

  1. Start Amazon Linux 2 and sign in. (I recommend an m6g.medium instance
@sijie
sijie / geo-replication-demo-without-a-global-zookeeper.md
Last active September 5, 2023 14:01
Geo Replication Demo without a global zookeeper

This doc demonstrates how to do geo-replication across multiple pulsar clusters without a global configuration store (zookeeper).

This demo is using docker-compose to start 3 pulsar clusters. Each pulsar cluster has 1 zk, 1 bk, and 1 broker. The docker compose file can be found at https://gist.github.com/sijie/63737459112471a82957ae20bd78adb5.

The information of all the three clusters is listed in the following table:

zk configuration store broker
beijing zk-beijing zk-beijing broker-beijing
@bgauduch
bgauduch / multiple-repository-and-identities-git-configuration.md
Last active July 17, 2024 12:57
Git config with multiple identities and multiple repositories

Setup multiple git identities & git user informations

/!\ Be very carrefull in your setup : any misconfiguration make all the git config to fail silently ! Go trought this guide step by step and it should be fine 😉

Setup multiple git ssh identities for git

  • Generate your SSH keys as per your git provider documentation.
  • Add each public SSH keys to your git providers acounts.
  • In your ~/.ssh/config, set each ssh key for each repository as in this exemple:
@henridf
henridf / protoc-encode.md
Last active May 29, 2024 22:08
Encoding a protobuf with `protoc --encode`

I needed to quickly encode a protobuf from the command-line, and while I pretty much immediately came across protoc --encode as the obvious solution, I did not find much documentation on the input textual syntax.

Here is the relevant snippet from protoc --help:

--encode=MESSAGE_TYPE       Read a text-format message of the given type
                              from standard input and write it in binary
                              to standard output.  The message type must
                              be defined in PROTO_FILES or their imports.
@tcnksm
tcnksm / NOTE.md
Last active April 13, 2024 21:28
Small note of gRPC Best Practice @ CoreOSFest 2017
@mtesseract
mtesseract / haskell-records.md
Last active March 8, 2023 22:25
Working around Haskell's namespace problem for records

The Problem

Defining records in Haskell causes accessor functions for the record's fields to be defined. There is no seperate namespace for these accessor functions.

The Goal

Be able to

  • use records in Haskell, which share field names.
  • use lenses for accessing these fields
# Pull the necessary images:
docker pull nathanleclaire/curl:latest
docker pull openjdk:8u111-jre-alpine

# Start the controller container, note that it has RW access to the Docker API socket:
docker run \
  -ti \
  --rm \