Permutation?

This was a simple algorithm taught in Discrete Math (which i learned and forgot...many years ago)

what I want to find out is the total number of possibility for the following

A B C

result in

A BC

ABBC

AC

ABC

which the total is 7

now suppose it's ABCD or ABCDE or ABCDEFGHIJKLMNOP

i need to know the total

anyone can refreash me on this

[423 byte] By [tnguyen] at [2007-9-30 9:03:12]
# 1
This is a pretty simple pattern to figure out, even if you don't remember:num elements -> combinations1 - 12 - 33 - 74 - 155 - 31...you can figure out the pattern is simply 2^N - 1
jboeing at 2007-7-2 20:57:50 > top of Java-index,Other Topics,Algorithms...
# 2
thanx jboeing.dud..i calculated the sequence wrong and couldn't figure out the formulai had 1,3,7,14,31the 14 throws me off.
tnguyen at 2007-7-2 20:57:50 > top of Java-index,Other Topics,Algorithms...