A programming language provides the following pre-defined functions.
move(n) = distance moved in pixels
rotate(d) = degrees turned (positive means clockwise)
These can be used by the programmer to draw lines.
A programmer writes the code to draw a square. The code is shown below.
Suggest a new pre-defined function that could be added to this programming language. (1)
Any suitable function. (1 mark)
For example:
- Polygon (any shape)
- Text tool
- Fill
Not “hexagon” or “square” as they are given in the question.