Wednesday, July 11, 2018

Day 4

Day 4!

Today, I mostly just went through the Code Academy Tutorials to learn Python. I am about 50% of the way through the content as of today, meaning that by Friday I will be a Python master! The further I go along learning Python, the trickier it gets. I know Java fairy well, so it can be confusing to relearn how to format functions I already know in Java. For example, "for loops" are quite different. In Java, I would format the initial statement as : for(int i = 0; i < 5; i++); , whereas in Python it is: for i in [list]: ... which is much different. Also, in Python there are "functions" that you can put tasks in to call upon using the function name, formatted as : def functionName(parameters), which again, differs drastically from Methods in Java, which look like:
public static *returnType* *methodName*(parameters)
I am getting used to it, but after a year of nothing but Java, it is taking a while for me to stop thinking in terms of brackets and semi-colons.

Near the end of the day, to test my fluency in Python, I decided to write up a code that would add up the amount of hours I work each day from my weekly time sheet. It took a while, I kept accidentally reverting to my old Java ways, but I ended up successful! Now, all I need to do to add up all the time I work per day is use my trusty program.

No comments:

Post a Comment

Day 28-29

Days 28 and 29 were spent on modifying the presentation. Yesterday, we did a dry run in front of our advisors and fellow interns. Before tha...