Result

WA

Duration

613ms

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
NO:
call write
leave
ret

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

stdin

21 05 90
32 05 52
09 47 08
48 41 01

stdout

 989

stderr

Segmentation fault (core dumped)

strace