{"id":2654,"date":"2017-11-17T18:38:28","date_gmt":"2017-11-17T18:38:28","guid":{"rendered":"http:\/\/webartdevelopers.com\/?p=2654"},"modified":"2017-11-17T18:38:28","modified_gmt":"2017-11-17T18:38:28","slug":"how-to-create-a-program-to-find-a-factorial-of-a-number-in-core-java","status":"publish","type":"post","link":"https:\/\/webartdevelopers.com\/blog\/how-to-create-a-program-to-find-a-factorial-of-a-number-in-core-java\/","title":{"rendered":"How to Create a Program to Find a Factorial of a Number in Core Java"},"content":{"rendered":"<p>In this tutorial how to find a Factorial of a number in Core Java\u00a0 is shown.<\/p>\n<p>Code:<\/p>\n<p>Factorial.java<\/p>\n<p>class Fact<br \/>\n{<br \/>\npublic static void main(String args[])<br \/>\n{<br \/>\nint number=Integer.parseInt(args[0]),fact=1,i;<br \/>\nfor(i=number;i&gt;0;i&#8211;)<br \/>\n{<br \/>\nfact*=i;<br \/>\n}<br \/>\nSystem.out.println(&#8220;Factorial of &#8220;+number+&#8221; is &#8220;+fact);<br \/>\n}<br \/>\n}<\/p>\n<p><a href=\"https:\/\/youtu.be\/qF5mN-X3PiI\">https:\/\/youtu.be\/qF5mN-X3PiI<\/a><\/p>\n<!-- AddThis Advanced Settings generic via filter on the_content -->","protected":false},"excerpt":{"rendered":"In this tutorial how to find a Factorial of a number in Core Java\u00a0 is shown. Code: Factorial.java class Fact { public static void main(String args) { int number=Integer.parseInt(args),fact=1,i; for(i=number;i&gt;0;i&#8211;) { fact*=i; } System.out.println(&#8220;Factorial of &#8220;+number+&#8221; is &#8220;+fact); } }<!-- AddThis Advanced Settings generic via filter on get_the_excerpt -->","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[156],"tags":[157,167],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/webartdevelopers.com\/blog\/wp-json\/wp\/v2\/posts\/2654"}],"collection":[{"href":"https:\/\/webartdevelopers.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/webartdevelopers.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/webartdevelopers.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/webartdevelopers.com\/blog\/wp-json\/wp\/v2\/comments?post=2654"}],"version-history":[{"count":2,"href":"https:\/\/webartdevelopers.com\/blog\/wp-json\/wp\/v2\/posts\/2654\/revisions"}],"predecessor-version":[{"id":2656,"href":"https:\/\/webartdevelopers.com\/blog\/wp-json\/wp\/v2\/posts\/2654\/revisions\/2656"}],"wp:attachment":[{"href":"https:\/\/webartdevelopers.com\/blog\/wp-json\/wp\/v2\/media?parent=2654"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/webartdevelopers.com\/blog\/wp-json\/wp\/v2\/categories?post=2654"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/webartdevelopers.com\/blog\/wp-json\/wp\/v2\/tags?post=2654"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}