Assembly Program In C

Example

Example

#include<stdio.h>

void main() {

   int a = 10, b = 20, c;

 

   asm {

      mov ax,a

      mov bx,b

      add ax,bx

      mov c,ax

   }

 

   printf("c= %d",c);

}

Output:

Note: We have executed this program on TurboC.

Input Required

This code uses input(). Please provide values below: