School Commit Init

This commit is contained in:
2024-08-31 12:07:21 +03:00
commit 0b130ee18c
2801 changed files with 4720552 additions and 0 deletions
@@ -0,0 +1,36 @@
;An unsigned number a on 32 bits is given. Print the hexadecimal
;representation of a, but also the results of the circular permutations
;of its hex digits.
bits 32
global start
extern exit,printf
import exit msvcrt.dll
import printf msvcrt.dll
%include "subprogram.asm"
segment data use32 class=data
format db "%X ",0
a dd 12ABCDEFh
permutations resd 8
segment code use32 class=code
start:
push dword [a]
push dword permutations
call subprogram
add ESP,4*2
mov ECX,8
label:
push ECX
push dword [permutations+ECX*8]
push dword format
call [printf]
add ESP,4*2
pop ECX
loop label
push dword 0
call [exit]