Skip to content

Instantly share code, notes, and snippets.

@isopen
isopen / news.rb
Created December 12, 2019 21:50
hot)fix
...
lang.each do |section|
articles = Utils.get_articles(json, section)
next unless articles
...
end
...
@isopen
isopen / categories.rb
Created December 13, 2019 10:21
if scripts are executed sequentially, then remove the static dependency calls
...
nod_bench = Benchmark.measure do
input_file = ...
...
<?php
...
/**
* https://github.com/yiisoft/yii/issues/1197
*
* @param bool $resetDefault
*
* @return $this|GxActiveRecord
*/
public function resetScope($resetDefault = true)
I. TON Ducks
1.
video: https://t.me/tonplay_chat/271/1229
I wanted to set a new world record for TON Ducks, but under the onslaught of two bulls, "Duck" flew into textures.
I think you need to check the field bounds check in TON Ducks (validation doesn't always work).
2.
- video: https://t.me/tonplay_chat/271/1155
AI is not very good at avoiding obstacles as I mentioned above, but then it turned out that his damage does not blow boxes.
() recv_external(slice in_msg) impure {
var signature = in_msg~load_bits(512);
var cs = in_msg;
var (msg_seqno, valid_until, stored_seqno, public_key) = (cs~load_uint(32), cs~load_uint(32), get_data().begin_parse().load_uint(32), get_data().begin_parse().load_uint(256));
throw_if(35, valid_until <= now());
throw_unless(33, msg_seqno == stored_seqno);
throw_unless(34, check_signature(slice_hash(in_msg), signature, public_key));
accept_message();
cs~touch();
while (cs.slice_refs()) {
@isopen
isopen / nasm_tdjson_example.asm
Created September 21, 2025 11:17
nasm_tdjson_example
; TDLib Minimal Linux Client in x86-64 Assembly (NASM)
;
; nasm -f elf64 -o nasm_tdjson_example.o nasm_tdjson_example.asm
; gcc -o nasm_tdjson_example nasm_tdjson_example.o -ldl -no-pie
; ./nasm_tdjson_example
section .data
; Error messages
lib_error db "Error: libtdjson.so not found", 10, 0
client_error db "Error: Failed to create client", 10, 0