If $f:A^*\rightarrow A*$ and $g:A^* \rightarrow A^*$ are partial recursive we want to prove $h:A^* \rightarrow A^*$ with the following definition is partial recursive $$ h(x) = \begin{cases} \lambda & f(x) = \lambda\\ g(x) & \textrm{otherwise} \end{cases} $$ for $x \in Dom(f)$.
One of my friends tried using a $\textrm{step}$ function that we know is primitive recursive and also partial recursive $$ \textrm{step}(x,y) = \begin{cases} C_{\lambda} & x = \lambda\\ y & \textrm{otherwise} \end{cases} $$ and defined $h(x) = \textrm{step}(f(x),g(x))$. but I think there is a problem here because we are not using the fact that $f$ and $g$ are partial recursive. Is this solution correct or not?