Step 1: Understand the given conditions.
We are given that \( \vec{A} \) and \( \vec{B} \) are unit vectors, which means \( |\vec{A}| = 1 \) and \( |\vec{B}| = 1 \).
We are also given two vectors \( \vec{C} = \vec{A} + 2\vec{B} \) and \( \vec{D} = 5\vec{A} - 4\vec{B} \).
The condition is that \( \vec{C} \) and \( \vec{D} \) are perpendicular.
Step 2: Use the condition for perpendicular vectors.
Two vectors are perpendicular if their dot product is zero.
\[
\vec{C} \cdot \vec{D} = 0
\]
Step 3: Substitute the expressions for \( \vec{C} \) and \( \vec{D} \) into the dot product equation.
\[
(\vec{A} + 2\vec{B}) \cdot (5\vec{A} - 4\vec{B}) = 0
\]
Step 4: Expand the dot product using distributive property.
\[
\vec{A} \cdot (5\vec{A}) + \vec{A} \cdot (-4\vec{B}) + (2\vec{B}) \cdot (5\vec{A}) + (2\vec{B}) \cdot (-4\vec{B}) = 0
\]
\[
5(\vec{A} \cdot \vec{A}) - 4(\vec{A} \cdot \vec{B}) + 10(\vec{B} \cdot \vec{A}) - 8(\vec{B} \cdot \vec{B}) = 0
\]
Step 5: Use the properties of the dot product: \( \vec{X} \cdot \vec{X} = |\vec{X}|^2 \) and \( \vec{X} \cdot \vec{Y} = \vec{Y} \cdot \vec{X} \).
\[
5|\vec{A}|^2 - 4(\vec{A} \cdot \vec{B}) + 10(\vec{A} \cdot \vec{B}) - 8|\vec{B}|^2 = 0
\]
\[
5|\vec{A}|^2 + 6(\vec{A} \cdot \vec{B}) - 8|\vec{B}|^2 = 0
\]
Step 6: Substitute the magnitudes of the unit vectors \( |\vec{A}| = 1 \) and \( |\vec{B}| = 1 \).
\[
5(1)^2 + 6(\vec{A} \cdot \vec{B}) - 8(1)^2 = 0
\]
\[
5 + 6(\vec{A} \cdot \vec{B}) - 8 = 0
\]
\[
6(\vec{A} \cdot \vec{B}) - 3 = 0
\]
\[
6(\vec{A} \cdot \vec{B}) = 3
\]
\[
\vec{A} \cdot \vec{B} = \frac{3}{6} = \frac{1}{2}
\]
Step 7: Use the definition of the dot product to find the angle \( \theta \) between \( \vec{A} \) and \( \vec{B} \).
\[
\vec{A} \cdot \vec{B} = |\vec{A}| |\vec{B}| \cos \theta
\]
Substitute the known values:
\[
\frac{1}{2} = (1)(1) \cos \theta
\]
\[
\cos \theta = \frac{1}{2}
\]
For \( \theta \in [0, \pi] \), the angle is:
\[
\theta = \arccos\left(\frac{1}{2}\right) = \frac{\pi}{3}
\]
Step 8: Compare the result with the given options.
The angle between \( \vec{A} \) and \( \vec{B} \) is \( \pi/3 \), which matches option (B).