Solution:
a.
Let t∈{0,1,2,…,p−1}. Consider the remainders of t−ai, 1≤i≤m and bj, 1≤j≤n, modulo p. Their number is m+n>p and hence two of them are equal. Since the remainders of t−ai and t−aj, bi and bj, respectively, i=j, are different, it follows that t−ar≡bs(modp), i.e., ar+bs≡t(modp) for some r and s. Since t is an arbitrary remainder modulo p, we conclude that k=p.
b.
Let A={a1,a2,…,am} and B={b1,b2,…,bn}. For any two sets X and Y denote X+Y={x+y(modp)∣x∈X,y∈Y}. We have to prove that k=∣A+B∣≥m+n−1. To do this, we may assume that m≤n and we shall use induction on m.
For m=1 and any n the statement is true, since a1+bi=a1+bj(modp) if i=j and ∣a1+B∣=∣B∣=n=1+n−1.
Suppose that the statement is true for any two sets X and Y such that ∣X∣<m, ∣X∣<∣Y∣ and ∣X∣+∣Y∣≤p. Let ∣A∣=m>1 and ∣B∣=n, where m≤n and m+n≤p. Then n<p and hence there exists c∈/B. Take different a1,a2∈A. As the sequence c+t(a2−a1)(modp), t=1,2,…,p−1, contains all remainders except c, then b=c+t(a2−a1)∈B for some t. Let t be the minimal number with this property. The set A′={b−a2}+A contains the elements b−a2+a1 and b−a2+a2=b. Note that b−a2+a1=c+(t−1)(a2−a1)∈/B. Since ∣A′+B∣=∣{b−a2}+A+B∣, it is enough to prove that ∣A′+B∣≥m+n−1.
Set F=A′∩B and G=A′∪B. Since b∈F, b−a2+a1∈/F and b−a2+a1∈A′, then F is a proper non-empty subset of A′. So B is a proper subset of G. It follows that 0<∣F∣<m≤n<∣G∣. On the other hand, m+n=∣A′∣+∣B∣=∣A′∩B∣+∣A′∪B∣=∣F∣+∣G∣. Note also that F+G⊂A′+B (for f∈F and g∈G, we may assume that g∈A′ and then f∈F⊂B implies that f+g∈A′+B). Thus ∣A′∣+∣B∣≥∣F∣+∣G∣. Then the inequalities 0<∣F∣<m≤n<∣G∣, ∣F∣+∣G∣≤p and the induction hypotheses imply that the statement is true for the sets F and G. Hence
∣A+B∣=∣A′+B∣≥∣F+G∣≥∣F∣+∣G∣−1=∣A′∣+∣B∣−1=m+n−1
which completes the induction.