Initial Commit

This commit is contained in:
SoraKatadzuma committed 2026-10-28 22:13:49 -05:00
commit 05756094ac
706 files changed
+135430

No files matched your search

@@ -0,0 +1,8 @@
import std::io;
def bumped(m: maybe<int>): int { return m is some(v) ? v + 1 : 0; }
def doubled(m: maybe<int>): int { return m is not some(v) ? -1 : v * 2; }
def main(): void {
val none: maybe<int> = nothing {};
val four: maybe<int> = maybe::<int>{ some = 4 };
println($"{bumped(four)} {bumped(none)} {doubled(four)} {doubled(none)}");
}