I wrote the code for the function $T$ defined on $[0,1]$ by $T(x)=\frac{x+2}{3}$ if $x\neq\frac{1}{2}$ and $T(\frac{1}{2})=1$ as follows.
T[x_] := If[x != 1/2, (2*x + 1)/3, 1];
I am not sure if the code I wrote defines the function $T$ correctly as the command `Plot' fails to highlight the discontinuity at $\frac{1}{2}$.
A clarification to my doubt will be highly appreciated. Thanks!

Piecewise[]– Michael E2 Dec 17 '18 at 14:47{}button above the edit window. The edit window help button?is useful for learning how to format your questions and answers. You may also find this meta Q&A helpful – Michael E2 Dec 17 '18 at 14:47Piecewiseand see the answers here. – march Dec 17 '18 at 16:42