Mode:
Duration:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
section .text
global _start
_start:
mov al, 0 ; fib0
mov bl, 1 ; fib1
mov cl, 0 ; counter
fibonacci_loop:
; compute next
mov dl, al
add dl, bl
; update registers
mov al, bl
mov bl, dl
inc cl
cmp cl, 5
jl fibonacci_loop
; exit
mov eax, 60
xor edi, edi
syscallCoding works best on desktop or with an external keyboard.