class factorial
{
int f;
factorial()
{
f=1;
}
void disp()
{
for(int i=1;i<5;i++)
{
f=f*i;
System.out.println(f);
}
}
public static void main(String s[])
{
factorial f= new factorial();
f.disp();
}
}
This blog is mainly developed for individuals,who were interested in programming using C,C++,java and SQL.
0 comments:
Post a Comment