Write a Pseudo Code to fins the LCM of two given numbers

Answer Posted / shailendra

#include <iostream>
using namespace std;
int main()
{
int x,y,z;
cout<<"Enter First Integer:";
cin>>x;
cout<<"\nEnter Second Integer:";
cin>>y;
z=1;
while(x/z==1 && y/z==1)
{
z=x/y;
cout<<"The LCM of Both Numbers is:"<<z;
}
return 0;
}

Is This Answer Correct ?    8 Yes 69 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to change the color of a cell or a row in a datagrid on mouse hover using javascript/.net

1530


how pseudo column works?

1717


how to check single or double byte in struts

1551


what are stubs related to foxpro?

1654


What is the purpose of element of in Ajax

2011






where is available in this mantis toturials?

1607


HOW TO FIND NUMBER OF TWOS IN N!(N FACTORIAL)??

1781


What is dialog programming?

1580


Where do we need Operator overloading?

649


why not instantiating servet using new operator?

1491


Please forward important interview and basic questions in VB6 on my email id: usneha_16@yahoo.co.in

1569


How many forms can you create in a Visual Basic 6 Standard EXE project? Is there any limit on that?

1534


WS-NUM PIC S9(05)V(02) SIGN TRAILING SEPARATE MOVE '0050000+' TO WS-NUM The value stored is 00500,00+ MOVE '0050000-' TO WS-NUM Then what is the value will be stored in WS-NUM? Am getting '-00500,00'.....>>> What should I declare to WS-NUM so that I can get correct values for both + & - signs.

1846


Define distributed queries. can you explain me as soon as possible

1622


Given an array of size n+1 which contains all the numbers from 1 to n.Find the number which is repeated in O(n) time.How do you proceed with the same with floating numbers from 0 to 1 instead of 1 to n?

604