Email arrives with $T \sim Expo(1)$
Email is a spam with probability $p$ which is independent of T and another email.
Let X be the arriving time of the first spam email.
Let N be the number of emails received upto the first spam email.
I'm looking for $E(X) = E(E(X|N))$
For $E(X|N=n)$, I can interpret it two ways
given the first spam arrives at $N=n$ th email, expected time of X is n times $E(T) = n$
with definition of $E(X|N=n) = \int {x*p(x|N=n)} \,dx $
I can't proceed further from here
So the question is this, I can see the reasoning behind the #1, but it's weird that I can't actually express the reasoning in more detail, mathematically (#2 is an attempt to do that)
Is there a rigorous or intuitive explanation that can explain #1 in some other way?
In the end, all I learned is the definition of conditional probability
$ p(a|b) = p(a,b) / p(b) $
How is the definition being used in reasoning the #1?
Why can't I express #1 in terms of the definition?