@Dave: Thanks it really helped !! On Mon, Jun 7, 2010 at 6:16 AM, Dave <[email protected]> wrote:
> In number theory, a partition of a positive integer n is a way of > writing n as a sum of positive integers. Two sums that differ only in > the order of their summands are considered to be the same partition; > if order matters then the sum becomes a composition. The number of > partitions of n is given by the partition function p(n). You can > compute p(n) recursively. See > http://en.wikipedia.org/wiki/Partition_(number_theory)<http://en.wikipedia.org/wiki/Partition_%28number_theory%29> > . > > Dave > > On Jun 6, 2:05 pm, Raj N <[email protected]> wrote: > > How do you count the number of ways a number can be expressed as a sum > > of 2 or more numbers? > > For eg. if the number is 5 , count=3 i.e 1+1+1+1+1, 4+1, 3+2 > > note 2+3 is same as 3+2 > > -- > You received this message because you are subscribed to the Google Groups > "Algorithm Geeks" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<algogeeks%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/algogeeks?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.
