Advertisement
LincolnArantes

Remove primeiro caractere da string

Oct 27th, 2018
166
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ;Removendo o primeiro caractere da string
  2. ;Lincoln Cesar dos Reis Arantes
  3.  
  4. global _start
  5.  
  6. section .data
  7.     addr db "carros"
  8.  
  9. section .text
  10. _start:
  11.     mov [addr], byte ' ' ; altera a primeira letra
  12.     mov eax, 4    ; sys_write system call
  13.     mov ebx, 1    ; stdout file descriptor
  14.     mov ecx, addr ; bytes to write
  15.     mov edx, 8    ; number of bytes to write
  16.     int 0x80      ; perform system call
  17.    
  18.    
  19.     mov eax, 1    ; sys_exit
  20.     mov ebx, 0    ; exit
  21.     int 0x80
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement