What is the midpoint of hypotenuse in right angled triangle?

As $C$ is mid point so $OC = BC = \frac{\vec{b}}{2}$

Not that it matters to the following, but the second vector is reversed: $\;\overrightarrow{OC} = \overrightarrow{CB} = \frac{\vec b}{2}\,$.

$AC = \frac{\vec{b}}{2} - \vec{a}$

Let for brevity $\,\vec c = \overrightarrow{OC} = \frac{\vec b}{2}\,$, then $\overrightarrow{AC} = \vec c - \vec a\,$

I am not getting the value of AC as $\frac{\vec{b}}{2}$

That equality is obviously not true as vectors, but what we actually need to get is $|\vec{AC}| = \big|\frac{\vec{b}}{2}\big|=|\vec c|\,$.

In order to get the magnitude of $|\vec{AC}|$ and prove that equality, we have to use the fact that $\triangle OAB$ is a right triangle. The premise $OA \perp AB$ translates in vector notation to the dot product being $0\,$: $$\overrightarrow{OA} \cdot \overrightarrow{AB} = 0 \quad\iff\quad \vec a \cdot (\vec b - \vec a) = 0 \quad\iff\quad \vec a \cdot \vec b - |\vec a|^2 = 0 \tag{1}$$

Since $\vec b = 2\,\vec c$ relation $(1)$ can also be written as:

$$2\,\vec a \cdot \vec c - |\vec a|^2 = 0 \tag{2}$$

Using $(2)\,$, it follows that:

$$ \require{cancel} |\vec{AC}|^2 = \overrightarrow{AC} \cdot \overrightarrow{AC} = (\vec c - \vec a) \cdot (\vec c - \vec a) = |\vec c|^2 \cancel{- 2\,\vec a \cdot \vec c} + \cancel{|\vec a|^2} = |\vec c|^2 \tag{3} $$

Therefore $|\vec{AC}|^2 = |\vec{OC}|^2\,$, so $|AC| = |OC|\,$ and, since $|OC|=|BC|\,$, $\;|AC|=|OC|=|BC|$.