Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "stdafx.h"
- #include <iostream>
- using namespace std;
- int main() {
- int a, b, d, rest;
- a = 2277474;
- _asm {
- mov eax, a
- mov ecx, 0
- mov ebx, 10
- _while:
- cmp eax, 0
- je _endwhile
- mov edx, 0
- div ebx
- cmp edx, 7
- jne _not7
- inc ecx
- _not7:
- jmp _while
- _endwhile:
- mov b, ecx;
- /* shl eax, 2*/
- /* shr eax, 2*/
- /* rol eax, 2*/
- /* ror eax, 2*/
- /* mul cx === ax * cx */
- /* div b == dxax / b = ax rest dx */
- };
- cout << b;
- cout << endl;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement