how can i make an isalpha in nasm that takes the argv0 and prints it just in case it isalpha returns true, ie it contains letters, but i do not want to modify or delete what is not letters.
I found some cases here in the stackoverflow, but I was not able to modify them to start, since I'm a beginner in assembly.
Please, could you help me use this code along with a print using pure nasm, without c functions.
I also made this example code, I do not know if it is usable
section .text
global _start
_start:
push ebp
mov ebp, esp
mov ebx, [ebp+12]
cmp ebx, 0x00
jz exit
mov eax, ebx
strlen:
cmp byte [eax], 0x00
jz result
inc eax
jmp strlen
result:
sub eax, ebx
mov ecx, eax
isalpha:
mov dl, [ebx]
or dl, 0x20
sub dl, 'a'
cmp dl, 'z'-'a'
jna print
inc ebx
dec ecx
jnz isalpha
print:
lea edx, [eax+1]
mov ecx, ebx
mov BYTE [ecx+eax], 0xA
mov ebx, 0x1
mov eax, 0x4
int 0x80
exit:
mov eax, 0x1
mov ebx, 0x0
int 0x80