Skip to content

Instantly share code, notes, and snippets.

View object-Object's full-sized avatar
🏳️‍⚧️
[object Object]

[object Object] object-Object

🏳️‍⚧️
[object Object]
View GitHub Profile
@s5bug
s5bug / 0_initial_brainstorming.md
Last active June 13, 2025 02:03
Hex Casting compiler ideas

Basic Control Flow

Given an arbitrary program:

@main def lcm(a: Int, b: Int): Int =
  if(a < b) (a * (b / gcd(b, a))
  else (b * (a / gcd(a, b))

def gcd(a: Int, b: Int): Int =
  if(b == 0) a