<s>[INST] Maximum value of $p+q+r$ where $p=q(4-q), q=r(4-r), r=p(4-p)$ and $p,q,r\in R$ I would be grateful if somebody could please help me out.

Let $p,q,r\in R$. If $p=q(4-q), q=r(4-r), r=p(4-p)$, find the maximum value of $$p+q+r$$

My attempt:
$$p+q+r$$
$$=q(4-q)+(4-r)+(4-p)$$
$$=-(p^2+q^2+r^2-4p-4q-4r)$$
$$=-[(p-2)^2+(q-2)^2+(r-2)^2-12]$$
$$=12-[(p-2)^2+(q-2)^2+(r-2)^2]$$
$$$$
$$\Rightarrow p+q+r=12-[(p-2)^2+(q-2)^2+(r-2)^2]$$
$$$$
Thus it remains to minimize $[(p-2)^2+(q-2)^2+(r-2)^2]$
This clearly attains its minimum value at $p=2,q=2,r=2$. Hence, it seems that the minimum value of $$p+q+r=12-[0]=12$$
This does not match with the given answer. 
$$$$
Additionally, I seem to be arriving at a contradiction since if $q=2$, $p=q(4-q)=2(4-2)=4$ (which clearly doesn't match with $p=2$) and so on for $r$ and $p$.
 [/INST] Since (Cauchy-Shwartz inequality) $$ {1\over 3}(p+q+r)^2 \leq p^2+q^2+r^2 $$
and $$ p^2+q^2+r^2= 3(p+q+r)$$
we have $$ {1\over 3}(p+q+r)^2 \leq 3(p+q+r)$$
we get $p+q+r\leq 9$.
Value $9$ is achieved if $p=q=r=3$. So $\max\{p+q+r\}=9$
</s>