back
A Function to Draw a Line
Note: There is a PowerPoint presentation to accompany this lesson located in the public directory (C++STUFF) entitled, "line_functions.ppt").

Let's look at a simple function to create a simple line.

Function of a line example

Assignment

Create a function that makes a filled rectangle. Make it so the user can decide:
  1. How far from the left it starts.
  2. How wide it is.
  3. How tall it is.
  4. What type of character it's made from.