This code makes two turtles in the begining, and sets them off at random directions. the green blocks give them energy, simulating the turtles eating the grass. This is used to survive, reproduce, and when in baby form eventually grow. If the energy level of the turtle reaches zero, the turtle dies and the body is removed from the simulation after a second.



Today using python, we were able to make two games, first a simple a number guessing game, where it thinks of a number, and when you guess it will tell you if the selected number is above or below your guess.

We also coded up a game of rock paper scissors, the amount of turns and victory are not coded in yet, I am still trying to figure that out, but the game using, r,p,s, for simplicity, it will tell you if you tied with it, beat it, lost to it, and how you did.

Using python I made a formula that only using squares, made this, 150 different squares, getting bigger each round makes this shape.

Today, we started by making a simple Y shape using the turtle commands in python. It sounds easy but requires more than three steps to make an accurate Y shown below.

Then I had a little fun with my code, adding a second split in the middle of the Y, then I thought, why stop there.



I started to have 4 Y's all branching off from a central point where they all intersect, a took that another step further and had them instead of horrizontal and verticle lines, had them go diagnol creating this snowflake like shape.


Later that day we Mr Farrell started us on the main goal of today, making fractals, The first of today was using the Y, but at the tip of the split on both ends of the Y, they also became smaller versions of it shown here, this is a level ten model.


On a website Mr Farrell showed us a different kind of fractal, one made up of squares, the same principal except much more complicated. Instead of being perfect half sized of the first square, they were the size of the square length square root, a different turn I did not see coming today. Finding the correct formula took some time and was much more complicated than the first Y fractal, we finnally got it to work, and below is a display The first being a "Level" 10 formula, takes a few minutes to form fully but simple, and a Level twenty. this one took a very long time to finnally form, over an hour, but was worth the wait. (Will add picteure next week when it has time to finish)

as you can see it is mad of hundreds of squares, and too many for most people to even count, but compared to a "Level" 20, this is tiny.


Home


Soldering/Circuits