In a black-and-white TV, the screen is coated with white phosphor and the electron beam "paints" an image onto the screen by moving the electron beam across the phosphor a line at a time. To "paint" the entire screen, electronic circuits inside the TV use the magnetic coils to move the electron beam in a "raster scan" pattern across and down the screen. The beam paints one line across the screen from left to right. It then quickly flies back to the left side, moves down slightly and paints another horizontal line, and so on down the screen.
In this figure, the blue lines represent lines that the electron beam is "painting" on the screen from left to right, while the red dashed lines represent the beam flying back to the left. When the beam reaches the right side of the bottom line, it has to move back to the upper left corner of the screen, as represented by the green line in the figure. When the beam is "painting," it is on, and when it is flying back, it is off so that it does not leave a trail on the screen. The term horizontal retrace is used to refer to the beam moving back to the left at the end of each line, while the term vertical retrace refers to its movement from bottom to top.
As the beam paints each line from left to right, the intensity of the beam is changed to create different shades of black, gray and white across the screen. Because the lines are spaced very closely together, your brain integrates them into a single image. A TV screen normally has about 480 lines visible from top to bottom. In the next section, you'll find out how the TV "paints" these lines on the screen.