My textbook says that in the deductive system of natural deduction every hypotesis must be discarded by a rule of inference and after being discarded, it cannot be used again in the deduction... But then it presented me to this derivation for $A \rightarrow (B \rightarrow (A \land B))$:
$[A]^1$ $[B]^2$
________________$(\land I)^2$
$A \land B$
________________$(\rightarrow I)\times2$
$A \rightarrow (B \rightarrow (A \land B))$
By $"(\rightarrow I)\times2"$, I'm assuming he firstly did $(\rightarrow I)^2$ and then $(\rightarrow I)^1$.
But that confused me. Shouldn't $B$ be discarded after $(\land I)^2$? Does only the implication insertion rule discard hypothesis?