I hereby claim:
- I am alphakai on github.
- I am alphakai (https://keybase.io/alphakai) on keybase.
- I have a public key ASBN9H3xYiXbY3Ay4NMfosF-Ai9eqqpcP3WfOBO2KAMkRAo
To claim this, I am signing this object:
| /* Copyright 2021 @ Keychron (https://www.keychron.com) | |
| * | |
| * This program is free software: you can redistribute it and/or modify | |
| * it under the terms of the GNU General Public License as published by | |
| * the Free Software Foundation, either version 2 of the License, or | |
| * (at your option) any later version. | |
| * | |
| * This program is distributed in the hope that it will be useful, | |
| * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
I hereby claim:
To claim this, I am signing this object:
| #include <stdio.h> | |
| #include <string.h> | |
| void show_char_bits(char c) { | |
| for (size_t i = 0; i < 8; i++) { | |
| printf("%i", (c >> (7 - i)) & 1); | |
| } | |
| printf("\n"); | |
| } |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| #include <assert.h> | |
| #include <stdint.h> | |
| #include <stdbool.h> | |
| #include <limits.h> | |
| ////////////////////// Util ////////////////////// |
| import std; | |
| enum int[dchar] BabyTerm = [ | |
| 'ば' : 0b0000, | |
| 'ぶ' : 0b0001, | |
| 'マ' : 0b0010, | |
| '!' : 0b0011, | |
| ]; | |
| enum dchar[int] BabyTerm_R = [ |
| #include <stdio.h> | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <ucontext.h> | |
| #include <sys/time.h> | |
| #include <stdbool.h> | |
| void *xmalloc(size_t size) { | |
| void *ptr = malloc(size); |
| import core.sys.posix.setjmp; | |
| import std.stdio; | |
| import std.format; | |
| string yield(alias callee_env, alias caller_env, alias val)() { | |
| return q{ | |
| if (setjmp(%s) == 0) { | |
| longjmp(%s, %s); | |
| } | |
| }.format(callee_env.stringof, caller_env.stringof, val); |
| #[derive(Debug)] | |
| pub enum SexpObject { | |
| Float(f64), | |
| Bool(bool), | |
| String(String), | |
| Symbol(String), | |
| List(Vec<SexpObject>), | |
| } | |
| impl SexpObject { |
| 00100110000000000000000000000000 | |
| 00000001000000000000000000000001 | |
| 00100110000100010000000000000000 | |
| 00000001000100000000000000000100 | |
| 00100110001000100000000000000000 | |
| 00000001001000000000000000000011 | |
| 00000100000100100000000000000000 | |
| 00100110001000100000000000000000 | |
| 00000001001000000000000000000010 | |
| 00000010000100100000000000000000 |
| import std.stdio; | |
| import std.format; | |
| import std.traits; | |
| import std.array; | |
| mixin(q{ | |
| enum string fizzbuzz_code = { | |
| enum string prim_fb(int M)() { | |
| static if (M % 15 == 0) { return "writeln(\"fizzbuzz\");"; } | |
| else if (M % 3 == 0) { return "writeln(\"fizz\");"; } |