This simple program NASM outputs character 'A' instead of number 65:
section .data
var DB 65
section .text
global _start
_start:
mov edx, 1 ;message length
mov ecx, var ;message to write
mov ebx, 1 ;file descriptor (stdout)
mov eax, 4 ;system call number (sys_write)
int 0x80 ;call kernel
;exit
mov eax, 1 ;system call number (sys_exit)
int 0x80 ;call kernel
I want it to print the number.
All I found related to the topic were programs invloving printf which is not what I want.