How to make flag?

please format code with </> button * homework policy * asking questions


The flag should move once every few seconds to the right and then to the left

Hey and welcome to the forum!

Great to have you here!

Is this homework?

Please come up with some code of your own before we help with specific questions - this is forum policy…

Hint: use the reference: Language Reference (API) \ Processing 3+, check rect and triangle.

Draw first both triangles that you need.

Then we can discuss the animation.

see also: Processing Overview \ section Hello Mouse

Warm regards,