Suppose we have a bi-variate function like $f(x,y)$ which is concave in $x$, $\frac{d^2f(x,y)}{dx^2} = -g(x,y)<0$ (that is $f(x,y)$ can be a function with high order in $x$ ) but convex in $y$, that is $\frac{d^2f(x,y)}{dy^2}>0$ which is a second-order polynomial function in $y$. Here, if we assume that $0\le y \le 1$, I am wondering how to determine the optimal solution of the objective function? Because the function is convex in $y$, is it possible to say that the optimal value of $y$ is either 0 or 1, and we can determine the optimal value of $x$ condition on $y=0,1$? Also, the objective function is always nonnegative for all values of decision variables.
If this approach is not correct, please recommend a method to solve the problem.
\begin{equation} \begin{split} \max_{x \in R, 0\le y\le 1} f(x,y) \end{split} \end{equation}