The answer is that $2^7=128>100$.
To be more precise:
Say that you start by guessing $50$. Either you're right, in which case you're done, or you're wrong; if you're wrong, then you know that the number is either in $[1,49]$ or $[51,100]$, so that there are only $49$ or $50$ possibilities left.
Now, assuming that you aren't already done, you have a collection of $49$ or $50$ possibilities left; guess the middle one. That is, if you are on $[1,49]$, guess (say) $25$; if you're on $[51,100]$, then guess (say) $75$. If you got it right: great. If not, then you find out whether it should be higher or lower; in particular, if you previously knew it was in $[1,49]$, then you either now know it is in $[1,24]$ or you now know it is in $[26, 49]$. If you previously knew it was in $[51,100]$, then either you know that it is in $[51,74]$ or that it is in $[76,100]$.
In any case, you have either already guess right, or you have narrowed down the possibilities to one of $[1,24]$, $[26,49]$, $[51,74]$, or $[76,100]$. In any one of these cases, there are at most $25$ possibilities left, and it must be one of them.
Continue in this way: cut your current interval of possibilities in half by a guess, so that you are either right or you can discard roughly half of the possibilities based on the announcement of "higher" or "lower".
By continuing this process, in the third step you narrow it down to at most $12$ possibilities; in the fourth, to at most $6$; in the fifth, to at most $3$; in the sixth, to at most $1$; and voila! In your seventh guess, assuming that you're unlucky enough to have not guessed it yet, there's only one number that could possibly be it.
The provided solution is correct. When it computes the chance that somebody has a birthday on Jan 1, it doesn't care how many people share the birthday. Then it says each day has the same chance of being somebody's birthday and uses the linearity of expectation.
We can see what is going on with smaller numbers. Say we throw two dice and ask what is the expected number of different numbers seen. We can do the problem directly by saying the first die is some number. The second die has $\frac 56$ chance of adding a new number, so the expected number of distinct numbers seen is $\frac {11}6$. This is less than $2$ because of the chance that the two numbers are the same. The approach in the solution you quote is to say the chance $1$ does not appear is $(\frac 56)^2$, so the chance it does appear is $1-(\frac 56)^2=\frac {11}{36}$. Then the expected number of numbers we see is $6 \cdot \frac {11}{36}=\frac {11}6$
Best Answer
The answer posted by Jorge is right. Just to add some clarifications.
In the first try you have $\frac 1 {100}$ chance of guessing it right. On the second guess, your chance increases to $\frac 1 {99}$ as you know the answer isn't your guess and you aren't going to make the same guess. However, the probability that you are going to make the second guess (i.e. you guess the first one wrong) is $\frac {99} {100}$ so the probability is again, $\frac 1 {99}$ * $\frac {99} {100}$ = $\frac 1 {100}$. With same logic, your probability of guessing it right on the nth try is always $\frac 1 {100}$
The rest of the calculation checks out.
$$\sum\limits_{i=1}^{100} \frac{6-i}{100} = 6 - \frac{100\times 101}{2\times 100}=6-50.5=-45.5$$