Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- static int m[20];
- int ex2(int n){
- __asm{
- mov eax, 0
- mov eax, n
- mov ecx, 0
- for:
- mov [m + 4 * ecx], eax
- add eax, n
- inc ecx
- cmp ecx, 20
- jl for
- }
- }
- int main(){
- ex2(5);
- for (int i = 0; i < 20; i++){
- cout << m[i] << " ";
- }
- cout << endl;
- system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement