global _start
_start:

section .text

mov rax,1
mov rdi,1
mov rsi,msg1
mov rdx,len1
syscall

mov rsi,arr

l1:mov rax,[rsi]
push rsi
call display
pop rsi

add rsi,8
dec byte[cnt]
jnz l1

mov rax,60
mov rdi,0
syscall

display:
mov rsi,disparr +15
mov rcx,16

l3:mov rdx,0
mov rbx,10H

div rbx
cmp DL,09H
jbe l2

add DL,07H
l2:add DL,30H

mov[rsi],DL
dec rsi
dec rcx
jnz l3

mov rax,1
mov rdi,1
mov rsi,disparr
mov rdx,16
syscall

mov rax,1
mov rdi,1
mov rsi,endc
mov rdx,lenendc

syscall
ret

section .data
arr dq 1234567812345678H, 5242423535747446H, 8858557776555555H, 7655447786776664H, 5365423423675347H
cnt db 05H
msg1 db "ARRAY:",0ah
len1 equ $-msg1
endc db 0ah
lenendc equ $-endc

section .bss
disparr resb 32

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: