omega-mv
Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance.
Brought by drakestapleton
omega-mv / tools / exp445 / arms / examples / cube_xor_pair / program.osc
| 1 | fn cube_xor_pair(n: u8) -> u16 { |
| 2 | let t: own [u16; 16] = alloc(0); |
| 3 | for i in 0 .. 16 { |
| 4 | let v: u16 = i as u16; |
| 5 | t[i] = v * v * v; |
| 6 | } |
| 7 | let j: u32 = n as u32; |
| 8 | return t[j] ^ t[j + 1]; |
| 9 | } |