Tag Archives: Least

Write a recursive program in ‘C’ to find the L.C.M. (Least Common Multiple) of two given numbers. 10m Dec2006

Write a recursive program in ‘C’ to find the L.C.M. (Least Common Multiple) of two given numbers. 10m Dec2006 #include<stdio.h> int lcm(int,int); void main() { int NUM1,NUM2,LCM; clrscr(); printf(“ENTER ANY TWO POSITIVE NUMBERS TO FIND ITS L.C.M. : “); scanf(“%d%d”,&NUM1,&NUM2); if(NUM1>NUM2) LCM = lcm(NUM1,NUM2); else LCM = lcm(NUM2,NUM1); printf(“LCM OF TWO NUMBERS IS %d”,LCM); getch();… Read More »

ASSEMBLY19 An Assembly program to find the LCM Least Common Multiplier of two 16-bit unsigned integers

Now we will write another Assembly program to find the LCM Least Common Multiplier of two 16-bit unsigned integers. The above Logic is a C like Program to Find LCM we need its GCD or HCF first beacuse there is small Formula Shown above in a very simple way, So Just we will covert the logic into Assembly There… Read More »