Write a function do graphics that will take a list as input


Problem

Write a function do Graphics that will take a list as input. The function do Graphics will start by creating a canvas from the 640x480.jpg file in the media sources folder. You will draw on the canvas according to the commands in the input list. Each element of the list will be a string. There will be two kinds of strings in the list:

• "b 200 120" means to draw a black dot at x position 200 and y position 120-(200,120). The numbers, of course, will change, but the command will always be a "b." You can assume that the input numbers will always have three digits.

• "l 000 010 100 200" means to draw a line from position (0, 10) to position (100,200). So an input list might look like: ["b 100 200","b 101 200","b 102 200","l 102 200 102 300"] (but have any number of elements).

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: Write a function do graphics that will take a list as input
Reference No:- TGS02641134

Expected delivery within 24 Hours