Assignment
Activity no.3
Problem no. 5
#include"stdio.h"
#define p printf
#define s scanf
#define g gotoxy
main()
{
int n,x,product,y;
clrscr();
p("Enter n:");
s("%d",&n);
x=n;
product=1;
do
{
p("%dx",x);
product=product*x;
x=x-1;
}while(x!=1);
y=1;
p("%d",y);
p("=");
p("%d",product);
getch();
}
http://rapidshare.com/files/8124035/ISHIH.EXE.html
Problem no. 5
#include"stdio.h"
#define p printf
#define s scanf
#define g gotoxy
main()
{
int n,x,product,y;
clrscr();
p("Enter n:");
s("%d",&n);
x=n;
product=1;
do
{
p("%dx",x);
product=product*x;
x=x-1;
}while(x!=1);
y=1;
p("%d",y);
p("=");
p("%d",product);
getch();
}
http://rapidshare.com/files/8124035/ISHIH.EXE.html

0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home