This commit is contained in:
2025-06-01 19:54:35 +02:00
parent e84419f0cf
commit 437697b287
9 changed files with 44 additions and 25 deletions

View File

@@ -1,7 +1,7 @@
func print_i64[x: I64] : I64
printf("%ld\n", x)
func i64_to_string[n: I64] : String
func I64.to_string[n: I64] : String
let x: I64 = malloc(21)
sprintf(x, "%ld", n)
return x
@@ -14,7 +14,7 @@ func main[] : I64
let b: I64 = 500
while b < 1000
if a * b > out
let s: String = i64_to_string(a * b)
let s: String = I64.to_string(a * b)
let s_rev: String = strrev(s)
if strcmp(s, s_rev) == 0
out = a * b