Javascript change image onclick (specific patern) : So i'm new to javascript and i got this assignment:
"Find a figure with the number 1 and name it "one.jpg" on a page. Change the figure (figure 2) to "two.jpg" when it is clicked. Change after another click to "three.jpg" then back to "one.jpg"

howver i cannot seem to find a solution for this. all examples i found use buttons, anybody help?!
thank you.