zman7895's Turtle Logic Exercise

by Zach Lund

23 May 2017

Below is the embedded turtle trinket exercise.

This one I debated far longer about what I wanted to do with this exercise than the previous game I made. I guess you could say I wasn’t as passionate about this one, and it might show in the level of detail. However, I did eventually feel like I tested out the things we were supposed to utilize. I will also say my go at this exercise lacked the aha moments of the past. This might indicate I didn’t challenge myself enough. However, there were a couple of parts I did have to think through, and either figured out after a tiny bit, or I eventually found an alternate route that didn’t completely satisfy me, but would work.

The first example of one of these moments was deciding on the increments of my boolean logic. I wanted to include a wide range of temperatures and match them with gender in order to give a result. However, it quickly became clear that I would have to cover all ranges, and always include gender to get the result. For example, I wanted to have one range (a range of cold temperatures) where it didn’t matter if you put you were male or female, you got the same result. However, without indicating male or female, it screwed up the iteration of going through the original if statements. The second biggest issue I faced was figuring out how to only accept M or F for the gender. I learned how to downcase so it would accept both M or F and m or f within the if statements. But, it still accepts any other letter during the input and will just make it false all the way through my conditionals. I assume there is away to say it can only accept those specific string inputs, but I was unable to figure it out using a similar method to only accepting numbers when the variable type is a float. I will ask about this after class tomorrow.

Ultimately, I think this exercise fulfills the prompt, but due to time constraints and a few other things I had to do this evening, I didn’t get to throw my entire mind and heart into this exercise, and so I am not as thrilled about it as I was past exercises.

I am a rising senior at UNC and in the information science major. I lived most of my life just outside of Washington D.C. I love sports, music, and gambling. Find Zach Lund on Twitter, Github, and on the web.