# Probability involved in information theory.

I was reading Information, Entropy, and the Motivation for Source Codes chapter 2 MIT 6.02 DRAFT Lecture Notes(https://ocw.mit.edu/courses/electrical-engineering-and-computer-science/6-02-introduction-to-eecs-ii-digital-communication-systems-fall-2012/readings/MIT6_02F12_chap02.pdf, 2.1.2 Examples), trying to understand the mathematics behind information gain when I came across this:

Now suppose there are initially N equally probable and mutually exclusive choices, and I tell you something that narrows the possibilities down to one of M choices from this set of N. How much information have I given you about the choice? Because the probability of the associated event is M/N, the information you have received is log2(1/(M/N)) = log2(N/M) bits. (Note that when M = 1, we get the expected answer of log2 N bits.)

I could not understand how the probability of the associated event is M/N. Please explain in detail.

Suppose that $$C$$ is a random variable with values in a set $$\mathcal{C}$$ having a cardinality $$N$$. Suppose that all possible values of $$C$$ have the same probability.
Consider a subset $$\mathcal{C}'$$ of $$\mathcal{C}$$ that contains $$M$$ elements.
Then, if you consider the event $$E$$ : $$C \in \mathcal{C}'$$ then $$P(E)=\frac{M}{N}$$