Stdle #106 · branching · 2026-09-20
What does this Assembly snippet output?
A past puzzle — fully playable. 4 attempts, hints on wrong guesses.
.global _main.align 2_main: stp x29, x30, [sp, #-16]! mov w19, #0 mov w20, #1outer: mov w21, #1inner: add w19, w19, #1 add w21, w21, #1 cmp w21, #3 ble inner add w20, w20, #1 cmp w20, #3 ble outer sub sp, sp, #16 str x19, [sp] adrp x0, fmt@PAGE add x0, x0, fmt@PAGEOFF bl _printf add sp, sp, #16 ldp x29, x30, [sp], #16 mov w0, #0 ret.section __TEXT,__cstringfmt: .asciz "%d\n"Branching