Let me know if this proof is correct. This is in french.
Translation French --> English
prémisse = premise
supposition = assumption
I now know that this is 100% incorrect. Does anyone know how to resolve it mathematically?
.
Edit 1 : Thanks to @Mauro Curto here is what I came up with


$\def\fitch#1#2{~~\begin{array}{|l}#1\\\hline#2\end{array}}$
Not quite.
Conditional Introduction deduces a conditional statement whose antecedent is the assumption of a subproof and whose consequent is the conclusion. Thus when you assume $p$ with the aim of deriving $r$, you are intending to introduce $p\to r$ outside the context of that subproof.
Conversely, Conditional Elimination requires a conditional statement and its antecedent to both be accessible in the context where you intend to derive the consequent. Thus all such eliminations using the assumed conditionals of $p\to \textsf{whatever}$ must take place inside a context where $p$ is available.
That is in the innermost nest of the suproofs, which derives $q$ and $q\to r$, and from these another Conditional Elimination derives $r$. And so...
$$\fitch{~~1.~p\to(q\to r)}{\fitch{~~2.~p\to q}{\fitch{~~3.~p}{~~4.~q\\~~5.~q\to r\\~~6.~r}\\~~7.~p\to r}\\~~8.~(p\to q)\to(p\to r)}$$