Initial Commit

This commit is contained in:
SoraKatadzuma committed 2026-12-06 13:52:57 -06:00
commit 528ccf1523
782 files changed
+145156

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)}");
}