Programming Course for Beginners - ZedLX

The Easiest Online Computer Programming Course, for Free

Types point2D and colorA [5/8]

The function trianglep draws a triangle, where the vertices are given by the first three arguments, of type point2D.

The fourth argument of function trianglep is of type colorA. This argument is optional.

The signature of this function is:

  • void trianglep(
    • point2D p1,
    • point2D p2,
    • point2D p3,
    • /colorA cl
    • )

The keyword void indicates that the function does not return a value.

The forward slash / indicates that the parameter cl is optional.

Loading...