Discussion and sample code

Purpose:  To illustrate the most fundamental aspects of writing code to control the color of individual pixels.

A graphics frame with dimensions of 256x256 is placed on the screen.

Nested for loops are used to set the color values for each pixel in the frame.

The color ranges from mid-intensity blue in the upper left corner to subdued yellow in the bottom right corner.  (See Figure 1.)