then Penn would take the remaining 4 cards sum them up and take mod 5 of that.
Knowing the mod 5 of the remaining 4 cards, he will know the subset of cards the 5th card must be from.
for example:
take C = {3,35,56,93,100} WHERE C[0]=3 C[1]=35 C[2]=56 C[3]=93 C[4]=100 (in keeping with your convention)
then sum(C)mod 5 = 282 mod 5 = 2; Teller will give #56 (C[2]) back to the audience member and give C'={8,35,93,100} to Penn in a certain order
For Penn:
Let C' be the set of cards that he was given
Let C* be the set of possible cards that the audience member holds
Penn will sum(C') mod 5 = 236 mod 5 = 1
Knowing this information he can determine the subset of cards this will come from since if the card was:
C[0] then sum(C)mod 5 = 0 and C[0] mod 5 must be 4; thus C* can be = {4}; must be <8, or 8 would have been C_0
C[1] then sum(C)mod 5 = 1 and C[1] mod 5 must be 0; thus C* can be = {10,15,20,25,30}
C[2] then sum(C)mod 5 = 2 and C[2] mod 5 must be 1; thus C* can be = {36,41,46,51,56,61,66,71,76,81,86,91}
C[3] then sum(C)mod 5 = 3 and C[3] mod 5 must be 2; thus C* can be = {97};
C[4] then sum(C)mod 5 = 4 and C[4] mod 5 must be 3; thus C* can be = {103}
Thus Penn knows that C*={4,10,15,20,25,30,36,41,46,51,56,61,66,71,76,81,86,91,97,103}
Thus based on this information, Penn will have narrowed it down to a set of 20 cards (in this case); I think the largest set would have 22 cards. The order of the remaining 4 cards P(4,4)=24 can determine which element in the set it is. For example, we could arbitrarily set them being ordered smallest to largest as the first element in this set.
I think you could create some equations to simplify calculating the set:
Let k equal the set of integers where k>=0
C*=5k- sum(C') mod 5 when 5k<C'[0]
C*=5k - sum(C') mod 5 + 1, when C'[0]<5k<C'[1]
C*=5k - sum(C') mod 5 + 2, when C'[1]<5k<C'[2]
C*=5k - sum(C') mod 5 + 3, when C'[2]<5k<C'[3]
C*=5k - sum(C') mod 5 + 4 ,when 5k>C'[3]
which could be further simplified to C*=5k-sum(C') mod 5 + N, where N = the position of the card that was removed
In words: The set of possible cards in the audience member's hand can be determined by subtracting the sum of the 4 cards in Penn's hand modulo 5 from 5k, where k is the set of positive integers, and adding to it the possible position of the card removed. The element of this set can then be determined by the order in which the 4 cards are placed:
A<B<C<D
1 ABCD
2 ABDC
3 ACBD
4 ACDB
5 ADBC
6 ADCB
.
.
.
24 DCBA
Though complicated looking, I believe k can match up with the number assigned to these combinations; so as Penn, you would have to memorize the 24 combinations. In this case, you would use combination 11 (it is the 11th element in C*). If k=11, then 5*k=55 which is between C'[1] and C'[2], so then N=2 and C'mod5=1 so 5*k-1+2=56.
Similarly, it should be easy for Teller to know which combination to put the cards in as he can quickly do the equation backwards. He is removing C[2] since the sum modulo 5 was 2, and he can quickly calculate the modulo 5 of the sum of the remaining cards to be 1, and determine that 5k=55 and k=11.
In looking over the problem, this method will represent 24 elements k=1...24 and cards 1 to 124. I made a slight mistake in my equation since I am not representing 0 to 123.
As an aside, and out of curiosity -- what do you do QED?