Result

WA

Duration

618ms

Code [DL]

section .data
section .text
global _start

write:
push ebp
mov ebp, esp
mov edx, 1
mov ecx, ebp
add ecx, 8
mov ebx, 1
mov eax, 4
int 0x80
leave
ret

pi:
push ebp
mov ebp, esp
mov eax, [ebp+8]
cmp eax, 10
jl NO
mov edx, 0
mov ecx, 10
div ecx
push edx
push eax
call pi
mov eax, [esp+4] ; mod
add eax, 0x30
push eax
call write
NO:
leave
ret

_start:
push ebp
mov ebp, esp
push 8989
call pi
leave
ret

stdin

96 04 55
33 11 86
66 84 09
54 32 45

stdout

989

stderr

Segmentation fault (core dumped)

strace