So today is actually Day 5 for me, but I post a day behind because, well I do. I hadn’t had my coffee yet so I created a new file called “Day 4.” well, WHOOPS I wasn’t really thinking and I deleted all my Day 4 work. YIKES! OH NO!! Or so I thought for a moment. Well, I’m also learning Git and Github, (here’s a great video about learning Git), and trying to use version control in my work. I always upload to GH after I’m done and thankfully that little habit saved me from repeating Day 4 then doing Day 5.
Day 4 was learning how to use type annotation and that Swift is a strict/strong typed language meaning if a variable is created to be a string, it will ALWAYS AND ONLY be a string, so you can’t have something like:
var string = “String”
then later change it to
string = 123

Today was also the second challenge. It was using an array to hold a group of items, counting the items in the that array, then making a set based off of that array, which will cause any duplicates to be dropped. Then print the amount of items in that set, so it looks like this:

That was a lot of fun to do and think about.
Have fun, take care,
MJ
Leave a Reply