<s>[INST] What is the probability of the following event? Let $X_1, X_2, X_3, X_4$ be independent Bernoulli random variables. Then 
\begin{align}
Pr[X_i=1]=Pr[X_i=0]=1/2. 
\end{align}
I want to compute the following probability
\begin{align}
Pr( X_1+X_2+X_3=2, X_2+X_4=1 ). 
\end{align}
My solution: Suppose that $X_1+X_2+X_3=2$ and $X_2+X_4=1$. Then $(X_2, X_4)=(0,1)$ or $(1,0)$. The probabilities of $(X_2, X_4)=(0,1)$ and $(1,0)$ are both $1/2 \times 1/2 = 1/4$. If $(X_2, X_4)=(0,1)$, then $X_1+X_2+X_3=X_1+X_3=2$. Therefore $X_1 = X_3 =1$. This happens with probability $1/4$. If $(X_2, X_4)=(1,0)$, then $X_1+X_2+X_3=X_1+1+X_3=2$. Therefore $(X_1, X_3) \in \{(1,0), (0,1)\}$. This happens with probability $1/4$. Therefore 
\begin{align}
Pr( X_1+X_2+X_3=2, X_2+X_4=1 ) = 1/16+2/16=3/16. 
\end{align}
Is this correct? Thank you very much.
 [/INST] Just add as a supplementary technique:
You may also try to use the law of total probability with conditioning on $X_2$, since only $X_2$ are in common of the two events, then make use of the independence:
$$ \begin{align} &\Pr\{X_1 + X_2 + X_3 = 2, X_2 + X_4 = 1\} \\
=& \Pr\{X_1 + X_2 + X_3 = 2, X_2 + X_4 = 1|X_2 = 0\}\Pr\{X_2 = 0\} \\
&+ \Pr\{X_1 + X_2 + X_3 = 2, X_2 + X_4 = 1|X_2 = 1\}\Pr\{X_2 = 1\} \\
=& \Pr\{X_1 + X_3 = 2, X_4 = 1|X_2 = 0\}\Pr\{X_2 = 0\} \\
&+ \Pr\{X_1 + X_3 = 1, X_4 = 0|X_2 = 1\}\Pr\{X_2 = 1\} \\
=& \Pr\{X_1 + X_3 = 2\}\Pr\{X_4 = 1\}\Pr\{X_2 = 0\} + \\
&+ \Pr\{X_1 + X_3 = 1\}\Pr\{X_4 = 0\}\Pr\{X_2 = 1\} \\
=& \frac {1} {4}\times \frac {1} {2} \times \frac {1} {2} + \frac {1} {2} \times \frac {1} {2} \times \frac {1} {2} \\
=& \frac {3} {16}
\end{align}$$
So essentially you have counted the cases, just like what you have did.
</s>