SHARE
TWEET

ZNAK 0-9

kernel_memory_dump Apr 13th, 2014 101 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. .section .data
  2. str :  .ascii "c"
  3. C:   .byte 0
  4. .section .text
  5. .globl main
  6. main:
  7. #HashTag
  8. movb   str,  %al
  9. cmpb   $'0', %al
  10. jb   ne_pripada # bilo je manje od 48 , dakle ne pripada intervalu
  11. # AKO NIEJ SKOCIO, to znaci da je ili jednako ili vece od '0'
  12.  
  13. #SLEDECA PROVERA
  14. # da li je VECE od '9', ako jeste ne pripada
  15. cmpb  $'9', %al
  16. ja  ne_pripada      # vece je
  17. # AKO NIJE SKOCIO NIJEDNOM U SVOM ZIVOTU
  18. movb $42, C
  19. jmp kraj
  20.  
  21. ne_pripada
  22. movb $-42, C
  23.  
  24. kraj:
  25.         movl $1, %eax
  26.         mobl $0, %ebx
  27.         int $0x80
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top