Saturday, 15 February 2014

Week 6: Trees and Recursion

Assignment 1 actually went surprisingly well. After reading the sheet for the first time, I definitely considered dropping this class because I felt like I'd fallen behind too much. I was feeling like compsci and I hadn't really gotten close enough for me to complete something like that. However, after talking out the assignment with my partner- I realized what the overall idea for the program was. After getting a clear thought process in my head and thinking about how the data structures would work for stools and such, I could see what code was needed. Step 5 did take a bit of time, sweat and tears but I think the assignment went quite well. Seeing recursion work in a program that I partially designed was fulfilling as well as educational.

This week in lecture we went over trees, which use recursion. I found learning about recursion in this way quite helpful. I don't really understand what the value of learning about trees is, or how they can be used but I'll definitely be finding that out in the future.

The lab went well. My partner and I went through the steps quite quickly since we both seem to be understanding the application of recursion much more soundly than before. My one problem is that I don't always think to use recursion if I'm not told (such as in lab) "solve the problem by writing recursive code". I hope to eventually get to the point where I can see that I need to use recursion. I am able to trace the recursive code in my head and I understand how it works, I just need to work on realizing when it is useful in code.

Well, that's all my thoughts on compsci for this week. Comments are welcome.

Sunday, 9 February 2014

Week 5

I thought the lab went quite well this week. I struggled a bit with the initial concept, but once I could visualize what the function was meant to do, I could figure out the code with my partner. 

The assignment is definitely challenging. I should have started it early. Especially since I feel as though I'm not quite as good at coding as I should be for such an assignment. I definitely have some practice and catching up to do before the midterm later this month. 

I'm finally getting comfortable with classes and subclasses though, and I get the overall idea of inheritance and how it makes code simpler and less repetitive. 

Saturday, 1 February 2014

Week 4

I was down and out with strep during week 4 of lectures/lab, so I fell a little behind. I read up on the lecture slides and readings and I'm feeling decently up to date but I'm still struggling a bit.

However, I feel excited by the fact we're learning to code things that can actually be used. I'm working to keep up with the class because even though it's starting to get more and more difficult, it's getting quite exciting to learn code that has real application.

The concept and use of recursion is coming much more naturally to me than it did when we first learned it. So I've made progress there at the very least.

Thursday, 23 January 2014

Week 3: Object-Oriented Programming

This week's assigned topic is object-oriented programming, a term that comes up a lot in regards to programming. But what is it? 

Well at first I had no idea, because I was a bit on the late side with starting this class. But I now have caught up and understand the concept.

Object-oriented programming, or OOP, is the programming paradigm used in python. It is focused on creating objects, which have data and a behaviour. OOP allows programmers to represent abstract things in the real-world as objects in programs.  OOP also allows objects to build on each other, by having classes, sub-classes and so on.

Now what exactly does all of that mean? Since that is basically a summary of what was in the readings assigned in the first week.

Well the way I found made understanding it easier is to put in terms of a real-world example. So let's say a biologist wanted to virtually represent the classification of organisms. He may make a class to represent the three domains of life, which would each have attributes that describe the domain. For example, the domain eukarya would all have more than one cell with a nucleus. Then, there would be further classifications represented in subclasses. One sub-class would be animals, which would then be broken down further into classes such as mammals. Each sub-class would inherit attributes or characteristics from its mother class, which would in turn inherit from its mother class. By using objects that can hold data and code, it gives programmers the ability to make large, complex software in an organized way.

Overall, object-oriented programming makes programmer's lives a lot easier. It organizes code and puts it into a clear-cut hierarchy, which allows for the re-use of code that would otherwise be redundant. It allows a huge, complex program to be divided up into smaller, organized pieces which remain connected to each other. I can't imagine writing code in a different way, since this is the only way I've learned, but I imagine it would be difficult without the structure that OOP provides.

Welcome to my SLOG

I was a bit skeptical about writing a blog for a computer science course, but I'm very willing to see whether it will help me through the struggles of csc148.

I'll be updating this courSe LOG quite regularly to track my progress through this course. Hopefully, things go smoothly but that remains to be seen.