Why does the example normal shader multiply by "0.5 + 0.5"?

I’m learning how to write shaders. While I am understanding some of the basics of how shaders work. I am unsure on why somethings are done.

For example the normal shader on the examples page here, performs the following operation on the vertex normal:

v.normal * 0.5 + 0.5;

The shader is supposed to display the normal as a color, but what is the purpose of this operation?
Doesn’t it modify the actual color of the normal?

The normal is actually a 3 dimensional normalized vector. So each component of the normal is in the range -1 to 1. Of course using the normal as color will produce issues with negative numbers since colors are only specified between 0 to 1. Negative numbers would just be clamped to 0.

By multiplying the normal by 0.5 we essentially transform the original range from -1 to 1 into -0.5 to 0.5. By adding 0.5 to the result we shift everything by 0.5 so the new range is 0 to 1