HW 3 — Loops and Conditionals

Kihra Martinez
2 min readFeb 11, 2021

For this assignment, I used examples from our Lectures and added them together. Having to re-create these examples was hard, but cool.

  • I used three conditionals and 1 loop because I didn’t want too much moving around. By creating two ellipses and making them only turn black when the mouse hovered over them, I could then add a click option to make one of them move into a different position.
  • By making one of them move, I can make the other circle change by not changing position, but by making it move up, down, left, and right. By adding a gradient from white to black, it would change color while moving until you didn’t know where it was (black background). It’s not until you click on that circle, that it will turn white and have a white growing circle surround it.
  • Another thing I added was a simple loop. I didn’t want everything to look crowded, so I added the least crowded options. This loop would consist of many circles and move according to the mouse. By allowing the gradient into this loop, it will act just like the moving circle and become black when the mouse gets close to the circle.
  • Although it’s not the most interesting thing to the eye, having to try and catch the moving circle is super frustrating and addicting (to me). It’s simple and not too unpleasing to the eye. There are no rgb colors, which can be annoying, and there are not lots of moving objects. It can be thought almost like ping pong (simple, although this isn’t like a game).

--

--