9. Let $A=\{1,2,3, \cdots, 2 n, 2 n+1\}, B \subseteq A$, and for any three distinct elements $x, y, z$ in $B$, we have $x+y \neq z$. Find the maximum value of $|B|$.

Translate the above text into English, please retain the original text's line breaks and format, and output the translation result directly.