To find the factorial of a given number Posted on 02:29 by Unknown with No comments class Pro22 { public static void main(String arg[]) { int fact=1,i,n; n=Integer.parseInt(arg[0]); for(i=1;i<=n;i++) { fact=fact*i; } System.out.println(fact); } } Email ThisBlogThis!Share to XShare to Facebook
0 comments:
Post a Comment