+0  
 
+1
92
1
avatar+193 

Let

\[p(x,y) =
\begin{cases} x + y &\quad \text{if } x \ge 0 \text{ and } y \ge 0, \\
x - 2y &\quad \text{if } x < 0 \text{ and } y < 0, \\
3x + y &\quad \text{otherwise}.
\end{cases}
\]

What is $p(p(1,-1),p(-5,-2))$?

 Feb 12, 2021
 #1
avatar+86 
+4

@above, simply functional evaluation. For p(1,-1), then the case is 'otherwise' so we have 3*1-1=2. For p(-5,-2) we have case 2, so then -5-2(-2) equals -1. The outer function then has arguments 2 and -1, which is in the case 'otherwise' so we have 6-1=5.

 

So the final functional output is 5.

 Feb 13, 2021

57 Online Users

avatar
avatar
avatar
avatar