It’s the start of a new week! Actually, today’s Tuesday…I forgot to update last night 😐
However! After this past weekend, I feel energized, revitalized, and ready to go! We moved on to mySQL yesterday which is how we are going to be doing databases. I downloaded mySQL Workbench which is a GUI to help visualize how to structure your database. I like it because it’s got a visual aspect that’s a little different than coding. Here’s a picture of what a simple database can look like:
That pretty much sums up yesterday. There weren’t a bunch of assignments. Most of it was just readings and exercises to understand SQL. I finished up the lesson around 2pm and spent the remainder of my time finishing up two previous assignments from Flask.
Sidenote: Post class today having a much needed Bros night! Really looking forward to that!
Today was an EARLY one. I was the first one there again. I think I’m starting to like the calm right before everyone arrives. It’s pretty similar to when I was teaching. Loved getting to school an hour before sectionals to work done. I am hoping to adopt the same habits with coding!
Before it was time for algorithms, I was able to complete half of the Python Fundamentals in the learning platform. Our algorithm this morning was interesting. The goal was, given an array and a min and max value, find all values between min and max and move them to the front of the array while removing the values outside of the min and max. Seems simple enough! A good .pop or ought to take care of those values we want to remove. EXCEPT, we weren’t allowed to use an built in array methods…
Without giving away the answer, my partner and I spent about 35 minutes working through it. The aspect I love most about solving algorithms is it’s good practice at problem solving. In fact, I approach algorithms very similar to how I approach teaching.
Break down what the problem is asking. Don’t try to do too much all at once. Break it down to smaller parts.
Create a road map to the solution; also known as visualizing. Don’t work out any details in this step. It is meant to be very general and broad but it helps to set you in the right direction.
Time to code. If you have no idea where to begin, start with what you know. Just get SOMETHING down on paper…er…computer. (Actually, when working through algorithms, we aren’t allowed to use computers. We are discouraged from googling and testing code in the console. Instead, we do all of our work on the whiteboard with a dry erase marker.)
If you get stuck (more like WHEN you get stuck) don’t give up or get frustrated. Make a comment and move on. Leave it and come back. This was the hardest step for me to follow. I am very accustomed to making sure all of the pieces are in place before moving on to the next thing. Unfortunately, when coding, I wouldn’t get very far if I did that all of the time.
Once you have written all of the code, it is time to test your algorithm and find any breaks or crashes in the code. If you find a break, start at step 1 and break it down.
You could take the steps I have listed above and literally apply them to ANY situation or problem you might encounter in life.
I LOVE this about coding. It forces you to be a problem solver.
After algorithms, we had another short lecture this morning. Before the lecture, however, our instructor gives us an opportunity to ask any questions about homework assignments from the previous day. I always feel like I’m hogging all of the questions during this time…but I feel like if our instructor gives you an opportunity to pick his brain, you should take it! We continued with the lecture and we were introduced to Python functions and dictionaries. Functions in any coding language is a group of code then can accept parameters but it isn’t required. Functions also provide a means of reusing code without having to rewrite or copy code. Helps to keep your code “DRY”. Dictionaries are used to store information based off key-value pairs. When you wish to get some info, just call on it’s key to obtain the value.
The rest of the day was spent working on assignments until about 2:30pm. After that, we had a short group activity over dictionaries. When working in a group, we utilize “popcorn coding”. It involves only one computer and we all write a few lines of code and then switch out to the next person. This method of coding ensures that everyone has something to contribute to the final product. It also provides opportunities to learn from your peers if someone gets stuck or codes something incorrectly. I think it’s a great tool.
After the group activity I spent the last part of the afternoon finishing up my assignments for the day. Planning on staying ahead and reading the next module over Object Oriented Programming with Python!
Wow. This was kind of a long post and it probably wasn’t very interesting to read. I am still trying to figure out a balance between just throwing all my thoughts/experience in here versus creating an entertaining read for anyone subscribed. Let me know if you have any suggestions! I would love to hear from y’all!