Last active
March 5, 2019 06:19
-
-
Save siscodev93/b0277425e22deaede391da88bb4eb529 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <stdio.h> | |
| int add(int num1,int num2) | |
| { | |
| __asm { | |
| mov eax, num1 | |
| add eax, num2 | |
| } | |
| } | |
| int main() | |
| { | |
| int num1 = 10; | |
| int num2 = 5; | |
| int result = add(num1, num2); | |
| printf("Result: %d", result); | |
| return 1; | |
| } |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
For multiplication: