Expectation and Optimal Strategy I am trying to solve this below problem, but am having some difficulty.

Player A chooses a random integer between 1 and 100, with probability $p_j$ of choosing $j$ (for $j = 1, 2, \ldots , 100$). Player B guesses the number that player A picked, and receives from player A that amount in dollars if the guess is correct (and $0$ otherwise).
(a) Suppose for this part that player $B$ knows the values of $p_j$. What is player $B$’s optimal strategy (to maximize expected earnings)?
(b) Show that if both players choose their numbers so that the probability of picking $j$ is proportional to $1/j$, then neither player has an incentive to change strategies, assuming the opponent’s strategy is fixed.
(c) Find the expected earnings of player B when following the strategy from (b). Express your answer both as a sum of simple terms and as a numerical approximation. Does the value depend on what strategy player A uses?

Here is my best attempt so far at piecing this problem together.
(a) It seems rather obvious that player $B$ would maximize his expected earnings by choosing the value of $j$ such that $j \cdot p_j$ is highest. But, I am having difficulty formalizing this (or proving it mathematically) in terms of an equation for the expected value of $B$, especially since we know the probabilities that $A$ will choose some number, as does $B$, but not the probability that $B$ will guess some number. Isn't the expectation in the case the sum over the possible outcomes, multiplied by the probability that $B$ guesses correctly, given (conditioning on) the choice by $A$?
(b) If player $B$'s expected earnings are the sum of the integers from $1$ to $100$ (all the $j$'s) and the associated probability of the outcome is the probability both that player $A$ selected a particular integer, which is $p_j$, and the probability that player $B$ guessed that integer, which we can note as $\frac{a}{j}$ by proportionality, the the expectation collapses to $\sum j \cdot p_j \cdot \frac{a}{j} = \sum a p_j = a \sum p_j = a$ since these probabilities associated without the actions of players $A$ and $B$ are independent and the probabilities over all of the $p_j$'s sum to $1$ since player $A$ will have to choose something. Since $a$ is a constant, there is no incentive for $B$ to change his strategy. (Though it doesn't seem that $A$ can win anything, so I don't see why we would consider his strategy, unless his goal is to minimize $B$'s earnings.)
c) I can't figure out how to compute this since we chose it in part (b) to be an arbitrary constant.
I'd appreciate any helpful insights on this. Thanks in advance.

a) B should choose the $j$ that maximizes $jp_j.$  No departure from this can increase his expectation. If there is a $k\neq j$ such that $kp_k=jp_j,$ then choosing $k$ some of the time will leave the expectation unchanged.  Choosing $m$ with $mp_m<jp_j$ some of the time will lower the expectation.
b) We are told that $p_j={a\over j},$ but we know that $\sum_{j=1}^{100}{p_j}=1,$ so $${1\over a} =\sum_{j=1}^{100}{1\over j}$$  Now, whatever number B chooses, his expectation is $a$ and as long as A follows the same strategy, there can be no reason to change.  On the other hand, if we consider that B's strategy is fixed, the same consideration applies to A; whatever he does, his expectation is $-a$ so there is no incentive to change.
c) Since we know the expectation is $a,$ so this is just a matter of approximating $\sum_{j=1}^{100}{1\over j}$
