Received: by 10.66.86.130 with SMTP id p2mr2405080paz.22.1352350393819; Wed, 07 Nov 2012 20:53:13 -0800 (PST) Received: by 10.68.143.74 with SMTP id sc10mr1181561pbb.5.1352350393762; Wed, 07 Nov 2012 20:53:13 -0800 (PST) Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!nntp.club.cc.cmu.edu!newsfeed.news.ucla.edu!usenet.stanford.edu!kt20no35822925pbb.1!news-out.google.com!6ni68539pbd.1!nntp.google.com!kr7no36053567pbb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.java.programmer Date: Wed, 7 Nov 2012 20:53:13 -0800 (PST) In-Reply-To: <9b534783-eb45-458d-8abb-a4c890553971@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=173.8.104.241; posting-account=9nj3UAoAAABzqObz9JtEW6rWlTaThbpZ NNTP-Posting-Host: 173.8.104.241 References: <9b534783-eb45-458d-8abb-a4c890553971@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <8d95d877-c3c3-4d36-97f2-389424fdfc43@googlegroups.com> Subject: Re: How to do Combinations/Permutations in BlueJ From: lebaz95@gmail.com Injection-Date: Thu, 08 Nov 2012 04:53:13 +0000 Content-Type: text/plain; charset=ISO-8859-1 Xref: csiph.com comp.lang.java.programmer:19654 On Wednesday, November 7, 2012 8:28:19 PM UTC-6, leb...@gmail.com wrote: > I would like to create a program that will do problems like (xa+yb)^z. But I would need to do things like (5!/3!(5-3)!) How would I get this done? rslt = 1; for(i = e; i > 0; i --) { rslt *= i; } I asked my brother and he helped me. e in this program is a user input so you may replace it as you see fit.