Let P=(p1,p2,…,p7) be a permutation of the integers 1,2,…7. For how many permutations P are all seven sums S1=p1,S2=p1+p2,…,S7=p1+p2+⋯+p7 not multiples of 3?

Details and assumptions
A permutation is a rearrangement of the entire set of objects.

360