In the present study, the second order of accuracy difference scheme for numerical solution of the boundary value problem for the differential equation with an unknown parameter $p$ \[ \left\{\begin{align} & i\frac{du(t)}{dt}+Au(t)+iu(t)=f(t)+p, \quad 0<t<T, \\ & u(0)=\varphi, \quad u(T)=\psi \\ \end{align}\right. \] in a Hilbert space $H$ with self-adjoint positive definite operator $A$ is presented. Theorem on the stability of this difference scheme is established. The stability estimates for the solution of difference schemes for two determination of an unknown parameter problem for Schr\"odinger equations are given.