Logo 
Search:

Assembly Language Forum

Ask Question   UnAnswered
Home » Forum » Assembly Language       RSS Feeds

Code of Assembly Language

  Asked By: Mustabshir    Date: Nov 19    Category: Assembly Language    Views: 3198
  

How to Show String in Triangle Form like this?
K
KU
KUD
KUDC
KUDCS

Share: 

 

1 Answer Found

 
Answer #1    Answered By: Luis Vilera     Answered On: Nov 27

[segment.data]
msg : db " KUDCS",10
len : equ $-msg
retour db 10

[segment .bss]
[segment .text]
[global _start]
_start :

mov esi, 1

boucle:
mov eax, 4
mov ebx, 1

mov ecx, msg

mov edx, esi
int 0x80

mov eax, 4
mov ebx, 1

mov ecx, retour
mov edx, 1
int 0x80

inc esi
cmp esi, len-1
jb boucle

mov ebx, 0
mov eax, 1
int 0x80

 
Didn't find what you were looking for? Find more on Code of Assembly Language Or get search suggestion and latest updates.




Tagged: