I had this question in my exam. but my answer is wrong(I didn't receive explanations why...) $$f(\langle M\rangle,1^n)=\left \{ \texttt{the lexicographically smallest } x\in\left \{ 0,1 \right \}^n \cap L(M) \texttt{ if } n>100\texttt{ and }L(M)\cap \left \{ 0,1 \right \}^n \neq\varnothing \texttt{, otherwise undefined}\right \}$$
I answered it is computable.
for input $(\langle M\rangle,1^{n})$ when $n \geq101$
I run the machine on all possible inputs in $\Sigma^{n}$ and output the first result when conditions are
met.
I was wrong and apparently the language is not computable. what did I miss?