fixed bugs related to argument permutations and lists of arguments. tests added to confirm expected values. count now works as expected.