We know that, if $C\in\Bbb C$, $f$ is analytic in a domain $\Omega$ and there exists $\Lambda\subset \Omega$ with an accumulation point in $\Omega$ such that $f(z)=C$ for all $z\in \Lambda$ then $f\equiv C$. Now I am wondering if we can achieve the same conclusion if the hypothesis is that $|f(z)|=C$ for all $z\in \Lambda$. That is, it is true that
if $C>0$, $f$ is analytic in a domain $\Omega$ and there exists $\Lambda\subset \Omega$ with an accumulation point in $\Omega$ such that $|f(z)|=C$ for all $z\in \Lambda$ then $|f|\equiv C$, that is, $f$ is constant
?
No. Take $ \Omega= \mathbb C, f(z)=z, C=1 $ and $\Lambda=\{z \in \mathbb C: |z|=1\}.$